@arcgis/core 4.34.0-next.52 → 4.34.0-next.53

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 (87) hide show
  1. package/assets/esri/core/workers/RemoteClient.js +1 -1
  2. package/assets/esri/core/workers/chunks/{35fc8a64674005b1d1d7.js → 0a4357af5b8c0532b439.js} +1 -1
  3. package/assets/esri/core/workers/chunks/{b87ed14fde381f79bc9f.js → 17776d9d3558d45ea7b5.js} +1 -1
  4. package/assets/esri/core/workers/chunks/2efa4d8fe5454f8b2a05.js +1 -0
  5. package/assets/esri/core/workers/chunks/{a69e885336eb5d2729fd.js → 3505988ce3839cdbbc98.js} +1 -1
  6. package/assets/esri/core/workers/chunks/{46ab551bd19e52e73649.js → 3800764932a1c32cb29f.js} +1 -1
  7. package/assets/esri/core/workers/chunks/3c57b2e13628b5c1f6de.js +1 -0
  8. package/assets/esri/core/workers/chunks/{77493aa2118d462612a0.js → 43bd338bb0de375b9bb7.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{5a016dcd3192d42d363e.js → 5fc414fc2cfc68828c5b.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{ecd673eccf89643df07a.js → 659f7e99b2d524ef53fb.js} +2 -2
  11. package/assets/esri/core/workers/chunks/{037bc400257bc13b3ec8.js → 772e81e9162e2240a7a6.js} +1 -1
  12. package/assets/esri/core/workers/chunks/{f1de768b0a6d345f7e39.js → 8f6ff09e7d2f01b79faf.js} +1 -1
  13. package/assets/esri/core/workers/chunks/{cfa8b17cf1349f6ed355.js → 9e9be7f6ea32957f1088.js} +1 -1
  14. package/assets/esri/core/workers/chunks/9fef330b241f958b55df.js +1 -0
  15. package/assets/esri/core/workers/chunks/aab349d4624b78ef429f.js +1 -0
  16. package/assets/esri/core/workers/chunks/b9f5672093727c6f92c9.js +1 -0
  17. package/assets/esri/core/workers/chunks/bcc233a86e01ff1eac16.js +1 -0
  18. package/assets/esri/core/workers/chunks/cac060a187f3a27a19ba.js +1 -0
  19. package/assets/esri/core/workers/chunks/cda27c0fafd687dfa72e.js +1 -0
  20. package/assets/esri/core/workers/chunks/{82a390be9500b629f6bc.js → d0bf1fc6e3c198bc565d.js} +1 -1
  21. package/assets/esri/core/workers/chunks/dd2b5f115d156b5b212e.js +1 -0
  22. package/assets/esri/core/workers/chunks/e28d3ed65c3a76a044c8.js +1 -0
  23. package/assets/esri/core/workers/chunks/f75ddd79be506423be09.js +1 -0
  24. package/assets/esri/core/workers/chunks/{c5b2a261d8c216ca4a10.js → f8505bf69795f5293a79.js} +1 -1
  25. package/assets/esri/core/workers/chunks/fae6030a81cb91a91b69.js +1 -0
  26. package/assets/esri/core/workers/chunks/ff7962063d132c1ec814.js +1 -0
  27. package/assets/esri/themes/base/widgets/_FloorFilter.scss +23 -19
  28. package/assets/esri/themes/dark/main.css +1 -1
  29. package/assets/esri/themes/light/main.css +1 -1
  30. package/assets/esri/themes/light/view.css +1 -1
  31. package/config.js +1 -1
  32. package/interfaces.d.ts +2 -2
  33. package/kernel.js +1 -1
  34. package/layers/KMLLayer.js +1 -1
  35. package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
  36. package/layers/graphics/data/QueryEngine.js +1 -1
  37. package/layers/graphics/sources/WFSSourceWorker.js +1 -1
  38. package/layers/graphics/sources/geojson/GeoJSONSourceWorker.js +1 -1
  39. package/layers/graphics/sources/support/CSVSourceWorker.js +1 -1
  40. package/layers/graphics/sources/support/MemorySourceWorker.js +1 -1
  41. package/layers/support/ElevationQuery.js +1 -1
  42. package/layers/support/ExportImageParameters.js +1 -1
  43. package/networks/UtilityNetwork.js +1 -1
  44. package/package.json +3 -3
  45. package/portal/Portal.js +1 -1
  46. package/renderers/support/rasterRendererHelper.js +1 -1
  47. package/renderers/support/utils.js +1 -1
  48. package/rest/featureService/FeatureService.js +1 -1
  49. package/rest/print.js +1 -1
  50. package/support/revision.js +1 -1
  51. package/views/3d/analysis/ElevationProfile/HoveredPointsVisualization.js +1 -1
  52. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  53. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  54. package/views/3d/terrain/TerrainSurface.js +1 -1
  55. package/views/3d/webgl-engine/lib/Octree.js +1 -1
  56. package/views/draw/Draw.js +1 -1
  57. package/views/draw/support/Box.js +1 -1
  58. package/views/draw/support/GraphicMover.js +1 -1
  59. package/views/draw/support/Reshape.js +1 -1
  60. package/views/interactive/snapping/featureSources/GraphicsSnappingSource.js +1 -1
  61. package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
  62. package/views/layers/support/popupUtils.js +1 -1
  63. package/views/support/PromiseQueue.js +5 -0
  64. package/views/support/Scheduler.js +1 -1
  65. package/widgets/FeatureTable/Grid/support/ButtonMenu.js +1 -1
  66. package/widgets/FloorFilter/css.js +1 -1
  67. package/widgets/FloorFilter.js +1 -1
  68. package/widgets/HistogramRangeSlider.js +1 -1
  69. package/widgets/Sketch/SketchViewModel.js +1 -1
  70. package/widgets/support/ItemList.js +1 -1
  71. package/assets/esri/core/workers/chunks/0874b88d5ae7c2b78b3b.js +0 -1
  72. package/assets/esri/core/workers/chunks/0c129b78e5cfe96795e1.js +0 -1
  73. package/assets/esri/core/workers/chunks/1a3a4c2c642899be37a0.js +0 -1
  74. package/assets/esri/core/workers/chunks/37a97e690786814bf0b3.js +0 -1
  75. package/assets/esri/core/workers/chunks/48e64f99720907017778.js +0 -1
  76. package/assets/esri/core/workers/chunks/4d544e3e19ce07c2c195.js +0 -1
  77. package/assets/esri/core/workers/chunks/8c1bd9bcfc59497de3b5.js +0 -1
  78. package/assets/esri/core/workers/chunks/8cc700da2ac58849a708.js +0 -1
  79. package/assets/esri/core/workers/chunks/9b7fee0adffeee8d45ae.js +0 -1
  80. package/assets/esri/core/workers/chunks/9d30fed26e0d84ef893b.js +0 -1
  81. package/assets/esri/core/workers/chunks/b29f0b32787edb4e75cf.js +0 -1
  82. package/assets/esri/core/workers/chunks/c87bb42f825c39f9cce3.js +0 -1
  83. package/assets/esri/core/workers/chunks/f667096ea325f690c4a6.js +0 -1
  84. package/assets/esri/core/workers/chunks/f9f94b5efa9a64cdb407.js +0 -1
  85. package/layers/graphics/data/executeQueryForSnapping.js +0 -5
  86. package/layers/support/PromiseQueue.js +0 -5
  87. /package/assets/esri/core/workers/chunks/{ecd673eccf89643df07a.js.LICENSE.txt → 659f7e99b2d524ef53fb.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1210],{12543:(e,t,s)=>{s.r(t),s.d(t,{default:()=>_e});var i=s(31635),r=s(65529),n=s(74887),o=s(36708),a=s(10107),l=(s(44208),s(53966)),u=(s(87811),s(40608)),h=s(79897),c=s(16930),d=s(65864),f=s(58376),p=s(83221),g=s(95422),y=s(87045),_=s(61956),m=s(88625),v=s(66344),C=s(91869),w=s(83047),F=s(16271);function T(e=!1,t){if(e){const{elevationInfo:e,alignPointsInFeatures:s}=t;return new b(e,s)}return new I}class I{async alignCandidates(e,t,s){return e}notifyElevationSourceChange(){}}class b{constructor(e,t){this._elevationInfo=e,this._alignPointsInFeatures=t,this._alignmentsCache=new v.q(1024),this._cacheVersion=0}async alignCandidates(e,t,s){const i=this._elevationInfo;return null==i||"absolute-height"!==i.mode||i.featureExpressionInfo?this._alignComputedElevationCandidates(e,t,s):(function(e,t,s){const{offset:i,unit:r}=s;if(null==i)return;const n=(0,w.G9)(t),o=i*((0,F.Ao)(r??"meters")/n);for(const t of e)switch(t.type){case"edge":t.start.z+=o,t.end.z+=o;continue;case"vertex":t.target.z+=o;continue}}(e,t,i),e)}notifyElevationSourceChange(){this._alignmentsCache.clear(),this._cacheVersion++}async _alignComputedElevationCandidates(e,t,s){const i=new Map;for(const t of e)(0,C.tE)(i,t.objectId,M).push(t);const[r,o,a]=this._prepareQuery(i,t),l=await this._alignPointsInFeatures(r,s);if((0,n.Te)(s),a!==this._cacheVersion)return this._alignComputedElevationCandidates(e,t,s);this._applyCacheAndResponse(r,l,o);const{drapedObjectIds:u,failedObjectIds:h}=l,c=[];for(const t of e){const{objectId:e}=t;u.has(e)&&"edge"===t.type&&(t.draped=!0),h.has(e)||c.push(t)}return c}_prepareQuery(e,t){const s=[],i=[];for(const[t,r]of e){const e=[];for(const s of r)this._addToQueriesOrCachedResult(t,s.target,e,i),"edge"===s.type&&(this._addToQueriesOrCachedResult(t,s.start,e,i),this._addToQueriesOrCachedResult(t,s.end,e,i));0!==e.length&&s.push({objectId:t,points:e})}return[{spatialReference:t.toJSON(),pointsInFeatures:s},i,this._cacheVersion]}_addToQueriesOrCachedResult(e,t,s,i){const r=x(e,t),n=this._alignmentsCache.get(r);null==n?s.push(t):i.push(new S(t,n))}_applyCacheAndResponse(e,{elevations:t,drapedObjectIds:s,failedObjectIds:i},r){for(const e of r)e.apply();let n=0;const o=this._alignmentsCache;for(const{objectId:r,points:a}of e.pointsInFeatures){if(i.has(r)){n+=a.length;continue}const e=!s.has(r);for(const s of a){const i=x(r,s),a=t[n++];s.z=a,e&&o.put(i,a,1)}}}}class S{constructor(e,t){this.point=e,this.z=t}apply(){this.point.z=this.z}}function x(e,{x:t,y:s,z:i,spatialReference:r}){return`${e}-${t}-${s}-${i??0}}-wkid:${r?.wkid}`}function M(){return[]}class E{filter(e,t){return t}notifyElevationSourceChange(){}}class P{filter(e,t){const{point:s,distance:i}=e,{z:r}=s;if(null==r)return t;if(0===t.length)return t;const n=function(e){return"number"==typeof e?{x:e,y:e,z:e}:e}(i),o=this._updateCandidatesTo3D(t,s,n).filter(A);return o.sort(Z),o}_updateCandidatesTo3D(e,t,s){for(const i of e)switch(i.type){case"edge":j(i,t,s);continue;case"vertex":R(i,t,s);continue}return e}}function A(e){return e.distance<=1}function O(e=!1){return e?new P:new E}function j(e,t,{x:s,y:i,z:r}){const{start:n,end:o,target:a}=e;e.draped||function(e,t,s,i){const r=i.x-s.x,n=i.y-s.y,o=i.z-s.z,a=r*r+n*n+o*o,l=(t.x-s.x)*r+(t.y-s.y)*n+o*(t.z-s.z),u=Math.min(1,Math.max(0,l/a)),h=s.x+r*u,c=s.y+n*u,d=s.z+o*u;e.x=h,e.y=c,e.z=d}(a,t,n,o);const l=(t.x-a.x)/s,u=(t.y-a.y)/i,h=(t.z-a.z)/r;e.distance=Math.sqrt(l*l+u*u+h*h)}function R(e,t,{x:s,y:i,z:r}){const{target:n}=e,o=(t.x-n.x)/s,a=(t.y-n.y)/i,l=(t.z-n.z)/r,u=Math.sqrt(o*o+a*a+l*l);e.distance=u}function Z(e,t){return e.distance-t.distance}var z=s(4718),H=s(799);function q(e=!1,t){return e?new B(t):new k}class k{async fetch(){return[]}notifySymbologyChange(){}}class B{constructor(e){this._getSymbologyCandidates=e,this._candidatesCache=new v.q(1024),this._cacheVersion=0}async fetch(e,t){if(0===e.length)return[];const s=[],i=[],r=this._candidatesCache;for(const t of e){const e=N(t),n=r.get(e);if(n)for(const e of n)i.push((0,z.o8)(e));else s.push(t),r.put(e,[],1)}if(0===s.length)return i;const o=this._cacheVersion,{candidates:a,sourceCandidateIndices:l}=await this._getSymbologyCandidates(s,t);if((0,n.Te)(t),o!==this._cacheVersion)return this.fetch(e,t);const u=[],{length:h}=a;for(let e=0;e<h;++e){const t=a[e],i=N(s[l[e]]),n=r.get(i);n.push(t),r.put(i,n,n.length),u.push((0,z.o8)(t))}return i.concat(u)}notifySymbologyChange(){this._candidatesCache.clear(),this._cacheVersion++}}function N(e){switch(e.type){case"vertex":{const{objectId:t,target:s}=e,i=`${t}-vertex-${s.x}-${s.y}-${s.z??0}`;return(0,H.Wm)(i).toString()}case"edge":{const{objectId:t,start:s,end:i}=e,r=`${t}-edge-${s.x}-${s.y}-${s.z??0}-to-${i.x}-${i.y}-${i.z??0}`;return(0,H.Wm)(r).toString()}default:return""}}var L=s(65008),U=s(4576),$=s(60999),D=s(3483),J=s(13069),V=s(5443),Q=s(19419),K=s(90708),G=s(60694),Y=s(69418),W=s(80893);class X{constructor(e,t){this.data=e,this.resolution=t,this.state={type:0},this.alive=!0}process(e){switch(this.state.type){case 0:return this.state=this._gotoFetchCount(this.state,e),this.state.task.promise.then(e.resume,e.resume);case 1:case 3:break;case 2:return this.state=this._gotoFetchFeatures(this.state,e),this.state.task.promise.then(e.resume,e.resume);case 4:this.state=this._goToDone(this.state,e)}return null}get debugInfo(){return{data:this.data,featureCount:this._featureCount,state:this._stateToString}}get _featureCount(){switch(this.state.type){case 0:case 1:return 0;case 2:return this.state.featureCount;case 3:return this.state.previous.featureCount;case 4:return this.state.features.length;case 5:return this.state.previous.features.length}}get _stateToString(){switch(this.state.type){case 0:return"created";case 1:return"fetch-count";case 2:return"fetched-count";case 3:return"fetch-features";case 4:return"fetched-features";case 5:return"done"}}_gotoFetchCount(e,t){return{type:1,previous:e,task:(0,$.UT)(async e=>{const s=await(0,$.DZ)(t.fetchCount(this,e));1===this.state.type&&(this.state=function(e,t){return{type:2,featureCount:t,previous:e}}(this.state,s.ok?s.value:1/0))})}}_gotoFetchFeatures(e,t){return{type:3,previous:e,task:(0,$.UT)(async s=>{const i=await(0,$.DZ)(t.fetchFeatures(this,e.featureCount,s));3===this.state.type&&(this.state=function(e,t){return{type:4,previous:e,features:t}}(this.state,i.ok?i.value:[]))})}}_goToDone(e,t){return t.finish(this,e.features),{type:5,previous:e}}reset(){const e=this.state;switch(this.state={type:0},e.type){case 0:case 2:case 4:case 5:break;case 1:case 3:e.task.abort()}}intersects(e){return null==e||!this.data.extent||((0,Q.VY)(e,ee),(0,Q.HY)(this.data.extent,ee))}}const ee=(0,Q.vt)();let te=class extends L.A{get _minimumVerticesPerFeature(){switch(this.store?.featureStore.geometryType){case"esriGeometryPoint":case"esriGeometryMultipoint":return 1;case"esriGeometryPolygon":return 4;case"esriGeometryPolyline":return 2}}get _mandatoryOutFields(){const e=new Set;return this.objectIdField&&e.add(this.objectIdField),this.globalIdField&&e.add(this.globalIdField),e}set outFields(e){const t=this._get("outFields"),s=(0,D.KC)(e,this._mandatoryOutFields);(0,D.aI)(s,t)||(this._set("outFields",s),(0,D.Yy)(s,t)||this.refresh())}get outFields(){return this._get("outFields")??this._mandatoryOutFields}set filter(e){const t=this._get("filter"),s=this._filterProperties(e);JSON.stringify(t)!==JSON.stringify(s)&&this._set("filter",s)}set customParameters(e){const t=this._get("customParameters");JSON.stringify(t)!==JSON.stringify(e)&&this._set("customParameters",e)}get _configuration(){return{filter:this.filter,customParameters:this.customParameters,tileInfo:this.tileInfo,tileSize:this.tileSize}}set tileInfo(e){const t=this._get("tileInfo");t!==e&&(null!=e&&null!=t&&JSON.stringify(e)===JSON.stringify(t)||(this._set("tileInfo",e),this.store.tileInfo=e))}set tileSize(e){this._get("tileSize")!==e&&this._set("tileSize",e)}get updating(){return this._updatingHandles.updating}get hasZ(){return this.store.featureStore.hasZ}constructor(e){super(e),this.suspended=!0,this._historicMoment=null,this.tilesOfInterest=[],this.availability=0,this._pendingTiles=new Map,this._updatingHandles=new h.U}initialize(){this._initializeFetchExtent(),this._updatingHandles.add(()=>this._configuration,()=>this.refresh()),this._updatingHandles.add(()=>this.tilesOfInterest,()=>{this._updatePriorities(),this._process()},{sync:!0,initial:!0,equals:(e,t)=>(0,U.aI)(e,t,({id:e},{id:t})=>e===t)}),this.addHandles((0,o.z7)(()=>!this.suspended,()=>this._process()))}_updatePriorities(){this.store.setPriorityOrderByKey(this.tilesOfInterest.map(e=>e.id??"")??[])}destroy(){this._pendingTiles.forEach(e=>this._deletePendingTile(e)),this._pendingTiles.clear(),this.store.destroy(),this.tilesOfInterest.length=0,this._updatingHandles.destroy()}refresh(){this.store.refresh(),this._pendingTiles.forEach(e=>this._deletePendingTile(e)),this._process()}async handleEdits(e){if(e.historicMoment&&(this._historicMoment=e.historicMoment),!e.addedFeatures.length&&!e.updatedFeatures.length&&!e.deletedFeatures.length)return;for(const e of this._pendingTiles.values())e.reset();const t={...e,deletedFeatures:e.deletedFeatures.map(({objectId:e,globalId:t})=>e&&-1!==e?e:this._lookupObjectIdByGlobalId(t))},s=(0,$.UT)(async e=>{try{await this.store.processEdits(t,(e,t)=>this._queryFeaturesById(e,t),e),this._processPendingTiles()}catch(e){(0,n.QP)(e),l.A.getLogger(this).warn("Failed to apply edits",e)}});this.addHandles(s),await this._updatingHandles.addPromise(s.promise)}setHistoricMoment(e){e?.getTime()!==this._historicMoment?.getTime()&&(this._historicMoment=e,this.refresh())}_initializeFetchExtent(){if(!this.capabilities.query.supportsExtent||!(0,G.Wo)(this.url))return;const e=(0,$.UT)(async e=>{try{const t=await(0,W.Jf)(this.url,new _.A({where:"1=1",outSpatialReference:this.spatialReference,cacheHint:this.capabilities.query.supportsCacheHint??void 0}),{query:this._configuration.customParameters,signal:e});this.store.extent=V.A.fromJSON(t.data?.extent)}catch(e){(0,n.QP)(e),l.A.getLogger(this).warn("Failed to fetch data extent",e)}});this._updatingHandles.addPromise(e.promise.then(()=>this._process())),this.addHandles(e)}get debugInfo(){return{numberOfFeatures:this.store.featureStore.numFeatures,tilesOfInterest:this.tilesOfInterest,pendingTiles:Array.from(this._pendingTiles.values()).map(e=>e.debugInfo),storedTiles:this.store.debugInfo}}_process(){this._markTilesNotAlive(),this._createPendingTiles(),this._deletePendingTiles(),this._processPendingTiles()}_markTilesNotAlive(){for(const e of this._pendingTiles.values())e.alive=!1}_createPendingTiles(){if(this.suspended)return;const e=this._collectMissingTilesInfo();if(this._setAvailability(null==e?1:e.coveredArea/e.fullArea),null!=e)for(const{data:t,resolution:s}of e.missingTiles){const e=this._pendingTiles.get(t.id);e?(e.resolution=s,e.alive=!0):this._createPendingTile(t,s)}}_collectMissingTilesInfo(){let e=null;for(const t of this.tilesOfInterest){const s=this.store.process(t,(e,t)=>this._verifyTileComplexity(e,t),this.outFields);null==e?e=s:e.prepend(s)}return e}_deletePendingTiles(){for(const e of this._pendingTiles.values())e.alive||this._deletePendingTile(e)}_processPendingTiles(){const e={fetchCount:(e,t)=>this._fetchCount(e,t),fetchFeatures:(e,t,s)=>this._fetchFeatures(e,t,s),finish:(e,t)=>this._finishPendingTile(e,t),resume:()=>this._processPendingTiles()};if(this._ensureFetchAllCounts(e))for(const t of this._pendingTiles.values())this._verifyTileComplexity(this.store.getFeatureCount(t.data),t.resolution)&&this._updatingHandles.addPromise(t.process(e))}_verifyTileComplexity(e,t){return this._verifyVertexComplexity(e)&&this._verifyFeatureDensity(e,t)}_verifyVertexComplexity(e){return e*this._minimumVerticesPerFeature<re}_verifyFeatureDensity(e,t){if(null==this.tileInfo)return!1;const s=this.tileSize*t;return e*(ne/(s*s))<oe}_ensureFetchAllCounts(e){let t=!0;for(const s of this._pendingTiles.values())s.state.type<2&&this._updatingHandles.addPromise(s.process(e)),s.state.type<=1&&(t=!1);return t}_finishPendingTile(e,t){this.store.add(e.data,t),this._deletePendingTile(e),this._updateAvailability()}_updateAvailability(){const e=this._collectMissingTilesInfo();this._setAvailability(null==e?1:e.coveredArea/e.fullArea)}_setAvailability(e){this._set("availability",e)}_createPendingTile(e,t){const s=new X(e,t);return this._pendingTiles.set(e.id,s),s}_deletePendingTile(e){e.reset(),this._pendingTiles.delete(e.data.id)}async _fetchCount(e,t){return this.store.fetchCount(e.data,this.url,this._createCountQuery(e),{query:this.customParameters,timeout:ie,signal:t})}async _fetchFeatures(e,t,s){let i=0;const r=[];let n=0,o=t;for(;;){const a=this._createFeaturesQuery(e),l=this._setPagingParameters(a,i,o),{features:u,exceededTransferLimit:h}=await this._queryFeatures(a,s);l&&(i+=a.num),n+=u.length;for(const e of u)r.push(e);if(o=t-n,!l||!h||o<=0)return r}}_filterProperties(e){return null==e?{where:"1=1",gdbVersion:void 0,timeExtent:void 0}:{where:e.where||"1=1",timeExtent:e.timeExtent,gdbVersion:e.gdbVersion}}_lookupObjectIdByGlobalId(e){const t=this.globalIdField,s=this.objectIdField;if(null==t)throw new Error("Expected globalIdField to be defined");let i=null;const r=e?(0,J.AG)(e):e;if(this.store.featureStore.forEach(e=>{r===(0,J.AG)(e.attributes[t])&&(i=e.objectId??e.attributes[s])}),null==i)throw new Error(`Expected to find a feature with globalId ${e}`);return i}_queryFeaturesById(e,t){const s=this._createFeaturesQuery();return s.objectIds=e,this._queryFeatures(s,t)}_queryFeatures(e,t){return this.capabilities.query.supportsFormatPBF?this._queryFeaturesPBF(e,t):this._queryFeaturesJSON(e,t)}async _queryFeaturesPBF(e,t){const{sourceSpatialReference:s}=this,{data:i}=await(0,W.IJ)(this.url,e,new Y.S({sourceSpatialReference:s}),{query:this._configuration.customParameters,timeout:ie,signal:t});return(0,K.eY)(i)}async _queryFeaturesJSON(e,t){const{sourceSpatialReference:s}=this,{data:i}=await(0,W.eW)(this.url,e,s,{query:this._configuration.customParameters,timeout:ie,signal:t});return(0,K.q3)(i,{type:"object-id",fieldName:this.objectIdField})}_createCountQuery(e){const t=this._createBaseQuery(e);return this.capabilities.query.supportsCacheHint&&(t.cacheHint=!0),t}_createFeaturesQuery(e=null){const t=this._createBaseQuery(e),s=null!=e?.data?this.store.getAttributesForTile(e?.data?.id):null,i=(0,D.KC)((0,D.iv)(this.outFields,s??new Set),this._mandatoryOutFields);return t.outFields=Array.from(i),t.returnGeometry=!0,null!=e&&(this.capabilities.query.supportsResultType?t.resultType="tile":this.capabilities.query.supportsCacheHint&&(t.cacheHint=!0)),t}_createBaseQuery(e){const t=new _.A({returnZ:this.hasZ,returnM:!1,historicMoment:this._historicMoment,geometry:null!=this.tileInfo&&null!=e?(0,Q.w1)(e.data.extent,this.tileInfo.spatialReference):void 0}),s=this._configuration.filter;return null!=s&&(t.where=s.where,t.gdbVersion=s.gdbVersion,t.timeExtent=s.timeExtent),t.outSpatialReference=this.spatialReference,t}_setPagingParameters(e,t,s){if(!this.capabilities.query.supportsPagination)return!1;const{supportsMaxRecordCountFactor:i,supportsCacheHint:r,tileMaxRecordCount:n,maxRecordCount:o,supportsResultType:a}=this.capabilities.query,l=i?_.A.MAX_MAX_RECORD_COUNT_FACTOR:1,u=l*((a||r)&&n?n:o||se);return e.start=t,i?(e.maxRecordCountFactor=Math.min(l,Math.ceil(s/u)),e.num=Math.min(s,e.maxRecordCountFactor*u)):e.num=Math.min(s,u),!0}};(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"url",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"objectIdField",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"globalIdField",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"capabilities",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"sourceSpatialReference",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"spatialReference",void 0),(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],te.prototype,"store",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],te.prototype,"_minimumVerticesPerFeature",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"_mandatoryOutFields",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"outFields",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"suspended",void 0),(0,i.Cg)([(0,a.MZ)()],te.prototype,"_historicMoment",void 0),(0,i.Cg)([(0,a.MZ)()],te.prototype,"filter",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"customParameters",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],te.prototype,"_configuration",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"tileInfo",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"tileSize",null),(0,i.Cg)([(0,a.MZ)()],te.prototype,"tilesOfInterest",void 0),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],te.prototype,"updating",null),(0,i.Cg)([(0,a.MZ)({readOnly:!0})],te.prototype,"availability",void 0),(0,i.Cg)([(0,a.MZ)()],te.prototype,"hasZ",null),te=(0,i.Cg)([(0,u.$)("esri.views.interactive.snapping.featureSources.featureServiceSource.FeatureServiceTiledFetcher")],te);const se=2e3,ie=6e5,re=1e6,ne=25,oe=1;var ae=s(6518),le=s(72802);class ue{constructor(){this._store=new Map,this._priorities=new Map}get size(){return this._store.size}setPriorityOrderByKey(e){this._priorities.clear();for(let t=e.length-1;t>=0;t--)this._priorities.set(e[t],e.length-t)}hasLowerPriority(e){const t=this._priorities.get(e);if(null==t)return!0;for(const[e]of this._store){const s=this._priorities.get(e);if(null==s||s<t)return!0}return!1}someFromLowestToHighestPriority(e){const{_priorities:t}=this;for(const[s,i]of this._store)if(!t.has(s)&&e(i,s))return!0;for(const[s]of t){const t=this._store.get(s);if(t&&e(t,s))return!0}return!1}set(e,t){this._store.set(e,t)}delete(e){return this._store.delete(e)}get(e){return this._store.get(e)}has(e){return this._store.has(e)}clear(){this._store.clear()}values(){return this._store.values()}[Symbol.iterator](){return this._store[Symbol.iterator]()}}let he=class extends L.A{setPriorityOrderByKey(e){this._tiles.setPriorityOrderByKey(e)}get _memoryLimitExceeded(){return this.featureStore.usedMemory>=this.maximumByteSize}constructor(e){super(e),this.tileInfo=null,this.extent=null,this.maximumByteSize=10485760,this._tileBounds=new ae.F,this._tiles=new ue,this._refCounts=new Map,this._tileFeatureCounts=new Map,this._tmpBoundingRect=(0,Q.vt)()}add(e,t){for(const e of t)this._referenceFeature(e.objectId);const s=this.featureStore.upsertMany(t),i=s.map(e=>new Set(Object.keys(e.attributes))).reduce((e,t)=>(0,D.E$)(e,t),new Set(Object.keys(s[0]?.attributes??[]))),r=this._memoryLimitExceeded;this._addTileStorage(e,new Set(s.map(e=>e.objectId)),i),r&&this._applyCacheMemoryLimits()}_applyCacheMemoryLimits(){if(!this._memoryLimitExceeded)return;const{_tiles:e,featureStore:t,maximumByteSize:s}=this;e.someFromLowestToHighestPriority(e=>!this._memoryLimitExceeded||t.usedMemory-this._estimateRemoveTileMemoryReduction(e)<s||(this._removeTileStorage(e),!1))}_estimateRemoveTileMemoryReduction(e){let t=0;for(const s of e.objectIds)if(1===this._refCounts.get(s)){const e=this.featureStore.getFeature(s);e&&(t+=this.featureStore.estimateFeatureUsedMemory?.(e)??0)}return t}getAttributesForTile(e){return e?this._tiles.get(e)?.attributeKeys:null}destroy(){this.clear(),this._tileFeatureCounts.clear()}clear(){this.featureStore.clear(),this._tileBounds.clear(),this._tiles.clear(),this._refCounts.clear()}refresh(){this.clear(),this._tileFeatureCounts.clear()}processEdits(e,t,s){return this._processEditsDelete(e.deletedFeatures.concat(e.updatedFeatures)),this._processEditsRefetch(e.addedFeatures.concat(e.updatedFeatures),t,s)}_addTileStorage(e,t,s){const i=e.id;this._tiles.set(i,new ce(e,t,s)),this._tileBounds.set(i,e.extent),this._tileFeatureCounts.set(i,t.size)}_remove({id:e}){const t=this._tiles.get(e);t&&this._removeTileStorage(t)}_removeTileStorage(e){const t=[];for(const s of e.objectIds)1===this._unreferenceFeature(s)&&t.push(s);this.featureStore.removeManyById(t);const s=e.data.id;this._tiles.delete(s),this._tileBounds.delete(s)}_processEditsDelete(e){this.featureStore.removeManyById(e);for(const t of this._tiles.values()){for(const s of e)t.objectIds.delete(s);this._tileFeatureCounts.set(t.data.id,t.objectIds.size)}for(const t of e)this._refCounts.delete(t)}async _processEditsRefetch(e,t,s){if(!e.length)return;const i=(await t(e,s)).features,{hasZ:r,hasM:n}=this.featureStore;for(const e of i){const t=(0,K.jQ)(this._tmpBoundingRect,e.geometry,r,n);null!=t&&this._tileBounds.forEachInBounds(t,t=>{const s=this._tiles.get(t);this.featureStore.add(e);const i=e.objectId;s.objectIds.has(i)||(s.objectIds.add(i),this._referenceFeature(i),this._tileFeatureCounts.set(s.data.id,s.objectIds.size))})}}process(e,t=()=>!0,s){if(null==this.tileInfo||!e.extent||null!=this.extent&&!(0,Q.HY)((0,Q.VY)(this.extent,this._tmpBoundingRect),e.extent))return new fe(e);if(this._memoryLimitExceeded&&!this._tiles.hasLowerPriority(e.id??""))return new fe(e);const i=this.getAttributesForTile(e.id);if((0,D.Yy)(s,i))return new fe(e);const r=this._createTileTree(e,this.tileInfo);return this._simplify(r,t,null,0,1),this._collectMissingTiles(e,r,this.tileInfo,s)}get debugInfo(){return Array.from(this._tiles.values()).map(({data:e})=>({data:e,featureCount:this._tileFeatureCounts.get(e.id)||0}))}getFeatureCount(e){return this._tileFeatureCounts.get(e.id)??0}async fetchCount(e,t,s,i){const r=this._tileFeatureCounts.get(e.id);if(null!=r)return r;const n=await(0,W.gW)(t,s,i);return this._tileFeatureCounts.set(e.id,n.data.count),n.data.count}_createTileTree(e,t){const s=new de(e.level,e.row,e.col);return t.updateTileInfo(s,1),this._tileBounds.forEachInBounds(e.extent,i=>{const r=this._tiles.get(i)?.data;r&&function(e,t){if(!e||!t)return!1;if(e.level===t.level)return e.row===t.row&&e.col===t.col;const s=e.level<t.level,i=s?e:t,r=s?t:e,n=1<<r.level-i.level;return Math.floor(r.row/n)===i.row&&Math.floor(r.col/n)===i.col}(e,r)&&this._populateChildren(s,r,t,this._tileFeatureCounts.get(r.id)||0)}),s}_populateChildren(e,t,s,i){const r=t.level-e.level-1;if(r<0)return void(e.isLeaf=!0);const n=t.row>>r,o=t.col>>r,a=e.row<<1,l=o-(e.col<<1)+(n-a<<1),u=e.children[l];if(null!=u)this._populateChildren(u,t,s,i);else{const r=new de(e.level+1,n,o);s.updateTileInfo(r,1),e.children[l]=r,this._populateChildren(r,t,s,i)}}_simplify(e,t,s,i,r){const n=r*r;if(e.isLeaf)return t(this.getFeatureCount(e),r)?0:(this._remove(e),null!=s&&(s.children[i]=null),n);const o=r/2,a=o*o;let l=0;for(let s=0;s<e.children.length;s++){const i=e.children[s];l+=null!=i?this._simplify(i,t,e,s,o):a}return 0===l?this._mergeChildren(e):1-l/n<ge&&(this._purge(e),null!=s&&(s.children[i]=null),l=n),l}_mergeChildren(e){const t=new Set;let s;this._forEachLeaf(e,e=>{const i=this._tiles.get(e.id);if(i){s=s?(0,D.E$)(s,i.attributeKeys):new Set(i.attributeKeys);for(const e of i.objectIds)t.has(e)||(t.add(e),this._referenceFeature(e));this._remove(e)}}),this._addTileStorage(e,t,s??new Set),e.isLeaf=!0,e.children[0]=e.children[1]=e.children[2]=e.children[3]=null,this._tileFeatureCounts.set(e.id,t.size)}_forEachLeaf(e,t){for(const s of e.children)null!=s&&(s.isLeaf?t(s):this._forEachLeaf(s,t))}_purge(e){if(null!=e)if(e.isLeaf)this._remove(e);else for(let t=0;t<e.children.length;t++){const s=e.children[t];this._purge(s),e.children[t]=null}}_collectMissingTiles(e,t,s,i){const r=new pe(s,e,this.extent);return this._collectMissingTilesRecurse(t,r,1,i),r.info}_collectMissingTilesRecurse(e,t,s,i){const r=this.getAttributesForTile(e.id),n=r&&!(0,D.Yy)(i,r);if(n&&t.addMissing(e.level,e.row,e.col,s),e.isLeaf)return;if(!e.hasChildren)return void(n||t.addMissing(e.level,e.row,e.col,s));const o=s/2;for(let s=0;s<e.children.length;s++){const r=e.children[s];null==r?t.addMissing(e.level+1,(e.row<<1)+((2&s)>>1),(e.col<<1)+(1&s),o):this._collectMissingTilesRecurse(r,t,o,i)}}_referenceFeature(e){const t=(this._refCounts.get(e)||0)+1;return this._refCounts.set(e,t),1===t?0:2}_unreferenceFeature(e){const t=(this._refCounts.get(e)||0)-1;return 0===t?(this._refCounts.delete(e),1):(t>0&&this._refCounts.set(e,t),2)}get test(){}};(0,i.Cg)([(0,a.MZ)({constructOnly:!0})],he.prototype,"featureStore",void 0),(0,i.Cg)([(0,a.MZ)()],he.prototype,"tileInfo",void 0),(0,i.Cg)([(0,a.MZ)()],he.prototype,"extent",void 0),(0,i.Cg)([(0,a.MZ)()],he.prototype,"maximumByteSize",void 0),he=(0,i.Cg)([(0,u.$)("esri.views.interactive.snapping.featureSources.featureServiceSource.FeatureServiceTileStore")],he);class ce{constructor(e,t,s){this.data=e,this.objectIds=t,this.attributeKeys=s}}class de{constructor(e,t,s){this.level=e,this.row=t,this.col=s,this.isLeaf=!1,this.extent=null,this.children=[null,null,null,null]}get hasChildren(){return!this.isLeaf&&(null!=this.children[0]||null!=this.children[1]||null!=this.children[2]||null!=this.children[3])}}class fe{constructor(e,t=[]){this.missingTiles=t,this.fullArea=0,this.coveredArea=0,this.fullArea=(0,Q.Wc)(e.extent),this.coveredArea=this.fullArea}prepend(e){this.missingTiles=e.missingTiles.concat(this.missingTiles),this.coveredArea+=e.coveredArea,this.fullArea+=e.fullArea}}class pe{constructor(e,t,s){this._tileInfo=e,this._extent=null,this.info=new fe(t),null!=s&&(this._extent=(0,Q.VY)(s))}addMissing(e,t,s,i){const r=new le.U(null,e,t,s);this._tileInfo.updateTileInfo(r,1),null==r.extent||null!=this._extent&&!(0,Q.HY)(this._extent,r.extent)||(this.info.missingTiles.push({data:r,resolution:i}),this.info.coveredArea-=(0,Q.Wc)(r.extent))}}const ge=.18751;let ye=class extends r.nJ{constructor(){super(...arguments),this._isInitializing=!0,this.remoteClient=null,this._whenSetup=(0,n.Tw)(),this._elevationAligner=T(),this._elevationFilter=O(),this._symbologyCandidatesFetcher=q(),this._updatingHandles=new h.U,this._alignPointsInFeatures=async(e,t)=>{const s={query:e},i=await this.remoteClient.invoke("alignElevation",s,{signal:t});return(0,n.Te)(t),i},this._getSymbologyCandidates=async(e,t)=>{const s={candidates:e,spatialReference:this._spatialReference.toJSON()},i=await this.remoteClient.invoke("getSymbologyCandidates",s,{signal:t});return(0,n.Te)(t),i}}get updating(){return this._isInitializing||this._updatingHandles.updating||this._featureFetcher.updating}destroy(){this._featureFetcher?.destroy(),this._queryEngine?.destroy(),this._featureStore?.clear()}async setup(e){if(this.destroyed)return{result:{}};const{geometryType:t,objectIdField:s,timeInfo:i,fieldsIndex:r}=e.serviceInfo,{hasZ:n}=e,a=c.A.fromJSON(e.spatialReference);this._spatialReference=a,this._featureStore=new p.A({...e.serviceInfo,hasZ:n,hasM:!1}),this._featureStore.estimateFeatureUsedMemory=e=>e.usedMemory,this._queryEngine=new g.do({spatialReference:e.spatialReference,featureStore:this._featureStore,geometryType:t,fieldsIndex:r,hasZ:n,hasM:!1,featureIdInfo:{type:"object-id",fieldName:s},timeInfo:i}),this._featureFetcher=new te({store:new he({featureStore:this._featureStore}),url:e.serviceInfo.url,objectIdField:e.serviceInfo.objectIdField,globalIdField:e.serviceInfo.globalIdField,capabilities:e.serviceInfo.capabilities,spatialReference:a,sourceSpatialReference:c.A.fromJSON(e.serviceInfo.spatialReference),customParameters:e.configuration.customParameters});const l="3d"===e.configuration.viewType;return this._elevationAligner=T(l,{elevationInfo:null!=e.elevationInfo?m.A.fromJSON(e.elevationInfo):null,alignPointsInFeatures:this._alignPointsInFeatures}),this._elevationFilter=O(l),this.addHandles([(0,o.wB)(()=>this._featureFetcher.availability,e=>this.emit("notify-availability",{availability:e}),o.OH),(0,o.wB)(()=>this.updating,()=>this._notifyUpdating())]),this._whenSetup.resolve(),this._isInitializing=!1,this.configure(e.configuration)}async configure(e){return await this._updatingHandles.addPromise(this._whenSetup.promise),this._updateFeatureFetcherConfiguration(e),me}async setSuspended(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),this._featureFetcher.suspended=e,me}async updateOutFields(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),this._featureFetcher.outFields=new Set(e??[]),me}async fetchCandidates(e,t){await this._whenSetup.promise,(0,n.Te)(t);const s=function(e,t){const s=!!t||void 0;if(!e.filter)return{...e,query:{where:"1=1",returnZ:s}};const{distance:i,units:r,spatialRel:n,where:o,timeExtent:a,objectIds:l}=e.filter,u={geometry:e.filter.geometry?(0,d.rS)(e.filter.geometry):void 0,distance:i,units:r,spatialRel:n,timeExtent:a,objectIds:l,returnZ:s,where:o??"1=1"};return{...e,query:u}}(e,this._featureStore.hasZ),i=t?.signal,r=await(0,f.J)(this._queryEngine,s,i);(0,n.Te)(i);const o=await this._elevationAligner.alignCandidates(r.candidates,c.A.fromJSON(e.point.spatialReference)??c.A.WGS84,i);(0,n.Te)(i);const a=await this._symbologyCandidatesFetcher.fetch(o,i);(0,n.Te)(i);const l=0===a.length?o:o.concat(a);return{result:{candidates:this._elevationFilter.filter(s,l)}}}async updateTiles(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),this._featureFetcher.tileSize=e.tileSize,this._featureFetcher.tilesOfInterest=e.tiles,this._featureFetcher.tileInfo=null!=e.tileInfo?y.A.fromJSON(e.tileInfo):null,me}async refresh(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),this._featureFetcher.refresh(),me}async whenNotUpdating(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),await(0,o.C_)(()=>!this.updating,t),(0,n.Te)(t),me}async getDebugInfo(e,t){return(0,n.Te)(t),{result:this._featureFetcher.debugInfo}}async handleEdits(e,t){return await this._updatingHandles.addPromise(this._whenSetup.promise),(0,n.Te)(t),await this._updatingHandles.addPromise(this._featureFetcher.handleEdits(e)),(0,n.Te)(t),me}async setHistoricMoment(e,t){return this._featureFetcher.setHistoricMoment(e.moment),me}async notifyElevationSourceChange(e,t){return this._elevationAligner.notifyElevationSourceChange(),me}async notifySymbologyChange(e,t){return this._symbologyCandidatesFetcher.notifySymbologyChange(),me}async setSymbologySnappingSupported(e){return this._symbologyCandidatesFetcher=q(e,this._getSymbologyCandidates),me}_updateFeatureFetcherConfiguration(e){this._featureFetcher.filter=null!=e.filter?_.A.fromJSON(e.filter):null,this._featureFetcher.customParameters=e.customParameters}_notifyUpdating(){this.emit("notify-updating",{updating:this.updating})}};(0,i.Cg)([(0,a.MZ)({readOnly:!0})],ye.prototype,"updating",null),(0,i.Cg)([(0,a.MZ)()],ye.prototype,"_isInitializing",void 0),ye=(0,i.Cg)([(0,u.$)("esri.views.interactive.snapping.featureSources.featureServiceSource.FeatureServiceSnappingSourceWorker")],ye);const _e=ye,me={result:{}}},16271:(e,t,s)=>{s.d(t,{Ao:()=>n,KQ:()=>o});var i=s(4576),r=s(31756);function n(e){return 1/(r.j[e]||1)}const o=function(){const e=Object.keys(r.j);return(0,i.TF)(e,"decimal-degrees"),e.sort(),e}()},31756:(e,t,s)=>{s.d(t,{j:()=>n});var i=s(83047),r=s(79258);const n={unknown:1,inches:(0,i.oU)(1,"meters","inches"),feet:(0,i.oU)(1,"meters","feet"),"us-feet":(0,i.oU)(1,"meters","us-feet"),yards:(0,i.oU)(1,"meters","yards"),miles:(0,i.oU)(1,"meters","miles"),"nautical-miles":(0,i.oU)(1,"meters","nautical-miles"),millimeters:(0,i.oU)(1,"meters","millimeters"),centimeters:(0,i.oU)(1,"meters","centimeters"),decimeters:(0,i.oU)(1,"meters","decimeters"),meters:(0,i.oU)(1,"meters","meters"),kilometers:(0,i.oU)(1,"meters","kilometers"),"decimal-degrees":1/(0,i.vl)(1,"meters",r.$O.radius)}},60999:(e,t,s)=>{s.d(t,{DZ:()=>p,Ke:()=>f,Tj:()=>h,UT:()=>g,jJ:()=>u});var i=s(31635),r=s(65008),n=s(97768),o=s(74887),a=s(10107),l=s(40608);function u(e,t,s){return(0,o.Lx)(e.map((e,i)=>t.apply(s,[e,i])))}async function h(e,t,s){return(await(0,o.Lx)(e.map((e,i)=>t.apply(s,[e,i])))).map(e=>e.value)}function c(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function f(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return c(await e)}catch(e){return d(e)}}async function p(e){try{return c(await e)}catch(e){return(0,o.QP)(e),d(e)}}function g(e,t){return new y(e,t)}let y=class extends r.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,n.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:s}=this._abortController;this.promise=e(s),this.promise.then(e=>{this._result=c(e),this._cleanup()},e=>{this._result=d(e),this._cleanup()}),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,n.xt)(this._abortHandle),this._abortController=null}};(0,i.Cg)([(0,a.MZ)()],y.prototype,"value",null),(0,i.Cg)([(0,a.MZ)()],y.prototype,"error",null),(0,i.Cg)([(0,a.MZ)()],y.prototype,"finished",null),(0,i.Cg)([(0,a.MZ)()],y.prototype,"promise",void 0),(0,i.Cg)([(0,a.MZ)()],y.prototype,"_result",void 0),y=(0,i.Cg)([(0,l.$)("esri.core.asyncUtils.ReactiveTask")],y)},64272:(e,t,s)=>{s.d(t,{T:()=>d});var i,r=s(31635),n=s(25482),o=s(88930),a=s(10107),l=(s(44208),s(53966),s(87811),s(36005)),u=s(40608),h=s(43937),c=s(98623);let d=class extends n.o{static{i=this}static get allTime(){return f}static get empty(){return p}static fromArray(e){return new i({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(i.allTime)}get isEmpty(){return this.equals(i.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new i({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,s=this.end?.getTime()??this.end,i=e.start?.getTime()??e.start,r=e.end?.getTime()??e.end;return t===i&&s===r}expandTo(e,t=c.qU){if(this.isEmpty||this.isAllTime)return this.clone();let s=this.start;s&&(s=(0,o.lL)(s,e,t));let r=this.end;if(r){const s=(0,o.lL)(r,e,t);r=r.getTime()===s.getTime()?s:(0,o.S1)(s,1,e,t)}return new i({start:s,end:r})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return i.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,s=this.end?.getTime()??1/0,r=e.start?.getTime()??-1/0,n=e.end?.getTime()??1/0;let o,a;return r>=t&&r<=s?o=r:t>=r&&t<=n&&(o=t),s>=r&&s<=n?a=s:n>=t&&n<=s&&(a=n),null==o||null==a||isNaN(o)||isNaN(a)?i.empty:new i({start:o===-1/0?null:new Date(o),end:a===1/0?null:new Date(a)})}offset(e,t,s=c.qU){if(this.isEmpty||this.isAllTime)return this.clone();const r=new i,{start:n,end:a}=this;return null!=n&&(r.start=(0,o.S1)(n,e,t,s)),null!=a&&(r.end=(0,o.S1)(a,e,t,s)),r}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return f.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,s=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new i({start:t,end:s})}};(0,r.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,r.Cg)([(0,l.w)("end")],d.prototype,"readEnd",null),(0,r.Cg)([(0,h.K)("end")],d.prototype,"writeEnd",null),(0,r.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,r.Cg)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,r.Cg)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,r.Cg)([(0,l.w)("start")],d.prototype,"readStart",null),(0,r.Cg)([(0,h.K)("start")],d.prototype,"writeStart",null),d=i=(0,r.Cg)([(0,u.$)("esri.time.TimeExtent")],d);const f=new d,p=new d({start:void 0,end:void 0})},88625:(e,t,s)=>{s.d(t,{A:()=>v});var i,r=s(31635),n=s(69540),o=s(66552),a=s(25482),l=s(97768),u=s(10107),h=(s(44208),s(53966),s(87811),s(36005)),c=s(40608),d=s(43937),f=s(30524);let p=i=class extends a.o{constructor(e){super(e),this.expression=void 0,this.title=void 0}async collectRequiredFields(e,t){return(0,f.Dx)(e,t,this.expression)}clone(){return new i({expression:this.expression,title:this.title})}equals(e){return this.expression===e.expression&&this.title===e.title}};(0,r.Cg)([(0,u.MZ)({type:String,json:{write:{isRequired:!0}}})],p.prototype,"expression",void 0),(0,r.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],p.prototype,"title",void 0),p=i=(0,r.Cg)([(0,c.$)("esri.symbols.support.FeatureExpressionInfo")],p);const g=p;var y=s(16271);const _=(0,o.O)()({onTheGround:"on-the-ground",relativeToGround:"relative-to-ground",relativeToScene:"relative-to-scene",absoluteHeight:"absolute-height"}),m=new o.J({foot:"feet",kilometer:"kilometers",meter:"meters",mile:"miles","us-foot":"us-feet",yard:"yards"});let v=class extends((0,n.O)(a.o)){constructor(e){super(e),this.featureExpressionInfo=void 0,this.offset=null}readFeatureExpressionInfo(e,t){return null!=e?e.expression?e:void 0:t.featureExpression&&0===t.featureExpression.value?{expression:"0"}:void 0}writeFeatureExpressionInfo(e,t,s,i){t[s]=e.write({},i),"0"===e.expression&&(t.featureExpression={value:0})}get mode(){const{offset:e,featureExpressionInfo:t}=this;return this._isOverridden("mode")?this._get("mode"):null!=e||t?"relative-to-ground":"on-the-ground"}set mode(e){this._override("mode",e)}set unit(e){this._set("unit",e)}write(e,t){return this.offset||this.mode||this.featureExpressionInfo||this.unit?super.write(e,t):null}equals(e){return this.mode===e.mode&&this.offset===e.offset&&this.unit===e.unit&&(0,l.CM)(this.featureExpressionInfo,e.featureExpressionInfo)}};(0,r.Cg)([(0,u.MZ)({type:g,json:{write:!0}})],v.prototype,"featureExpressionInfo",void 0),(0,r.Cg)([(0,h.w)("featureExpressionInfo",["featureExpressionInfo","featureExpression"])],v.prototype,"readFeatureExpressionInfo",null),(0,r.Cg)([(0,d.K)("featureExpressionInfo",{featureExpressionInfo:{type:g},"featureExpression.value":{type:[0]}})],v.prototype,"writeFeatureExpressionInfo",null),(0,r.Cg)([(0,u.MZ)({type:_.apiValues,nonNullable:!0,json:{type:_.jsonValues,read:_.read,write:{writer:_.write,isRequired:!0}}})],v.prototype,"mode",null),(0,r.Cg)([(0,u.MZ)({type:Number,json:{write:!0}})],v.prototype,"offset",void 0),(0,r.Cg)([(0,u.MZ)({type:y.KQ,json:{type:String,read:m.read,write:m.write}})],v.prototype,"unit",null),v=(0,r.Cg)([(0,c.$)("esri.symbols.support.ElevationInfo")],v)}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3771],{13043:(e,t,n)=>{function r(e,t){if(e&&t)for(const n of e.children)if(n.localName in t){const e=t[n.localName];if("function"==typeof e){const t=e(n);t&&r(n,t)}else r(n,e)}}function*o(e,t){for(const n of e.children)if(n.localName in t){const e=t[n.localName];"function"==typeof e?yield e(n):yield*o(n,e)}}n.d(t,{i:()=>o,p:()=>r})},20437:(e,t,n)=>{n.d(t,{A:()=>m});var r,o=n(31635),i=n(66552),a=n(25482),s=n(10107),u=n(56507),l=(n(44208),n(87811),n(93223)),c=n(36005),p=n(40608),d=n(80451),y=n(98453);const f=new i.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",currency:"currency",dateAndTime:"date-and-time",description:"description",emailAddress:"email-address",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",phoneNumber:"phone-number",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let m=class extends a.o{static{r=this}constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?f.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,o.Cg)([(0,s.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,o.Cg)([(0,s.MZ)()],m.prototype,"description",void 0),(0,o.Cg)([(0,c.w)("description")],m.prototype,"readDescription",null),(0,o.Cg)([(0,s.MZ)({types:d.gK,json:{read:{reader:d.rS},write:!0}})],m.prototype,"domain",void 0),(0,o.Cg)([(0,s.MZ)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,o.Cg)([(0,s.MZ)({type:u.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],m.prototype,"length",void 0),(0,o.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,o.Cg)([(0,s.MZ)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,o.Cg)([(0,l.e)(y.m)],m.prototype,"type",void 0),(0,o.Cg)([(0,s.MZ)()],m.prototype,"valueType",void 0),(0,o.Cg)([(0,c.w)("valueType",["description"])],m.prototype,"readValueType",null),(0,o.Cg)([(0,s.MZ)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,o.Cg)([(0,p.$)("esri.layers.support.Field")],m)},33771:(e,t,n)=>{n.r(t),n.d(t,{default:()=>x});var r=n(60999),o=n(49186),i=n(53966),a=n(34727),s=n(74887),u=n(67076),l=n(21325),c=n(90708),p=n(58376),d=n(83221),y=n(31464),f=n(95422),m=n(85113),g=n(82832),h=n(34322),w=n(95466),b=n(54218),C=n(98623);const T="esri.layers.WFSLayer";class x{constructor(){this._customParameters=null,this._queryEngine=null,this._supportsPagination=!0}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){const{getFeatureUrl:n,getFeatureOutputFormat:r,fields:i,geometryType:a,featureType:u,maxRecordCount:l,maxTotalRecordCount:c,maxPageCount:p,objectIdField:m,customParameters:g}=e,{spatialReference:b,getFeatureSpatialReference:T}=(0,h.UH)(n,u,e.spatialReference);try{await(0,y.Nk)(T,b)}catch{throw new o.A("unsupported-projection","Projection not supported",{inSpatialReference:T,outSpatialReference:b})}(0,s.Te)(t),this._customParameters=g,this._featureType=u,this._fieldsIndex=w.A.fromLayerJSON({fields:i,dateFieldsTimeReference:i.some(e=>"esriFieldTypeDate"===e.type)?{timeZoneIANA:C.n$}:null}),this._geometryType=a,this._getFeatureUrl=n,this._getFeatureOutputFormat=r,this._getFeatureSpatialReference=T,this._maxRecordCount=l,this._maxTotalRecordCount=c,this._maxPageCount=p,this._objectIdField=m,this._spatialReference=b;let x=await this._snapshotFeatures(t);if(x.errors.length>0&&(this._supportsPagination=!1,x=await this._snapshotFeatures(t),x.errors.length>0))throw x.errors[0];const _={type:"object-id",fieldName:m};return this._queryEngine=new f.do({fieldsIndex:this._fieldsIndex,geometryType:a,hasM:!1,hasZ:!1,featureIdInfo:_,spatialReference:b,timeInfo:null,featureStore:new d.A({geometryType:a,hasM:!1,hasZ:!1})}),this._queryEngine.featureStore.addMany(x.features),{warnings:S(x),extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async applyEdits(){throw new o.A("wfs-source:editing-not-supported","applyEdits() is not supported on WFSLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),(await this._queryEngine.executeQueryForIds(e,t.signal)).filter(b.Et)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),(0,p.J)(this._queryEngine,e,t.signal)}async queryAttributeBins(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeAttributeBinsQuery(e,t.signal)}async refresh(e){return this._customParameters=e.customParameters,this._maxRecordCount=e.maxRecordCount,this._maxTotalRecordCount=e.maxTotalRecordCount,this._maxPageCount=e.maxPageCount,this._snapshotTask?.abort(),this._snapshotTask=(0,r.UT)(e=>this._snapshotFeatures({signal:e})),this._snapshotTask.promise.then(e=>{this._queryEngine.featureStore.clear(),this._queryEngine.featureStore.addMany(e.features);for(const t of S(e))i.A.getLogger(T).warn(new u.A("wfs-layer:refresh-warning",t.message,t.details));e.errors?.length&&i.A.getLogger(T).warn(new u.A("wfs-layer:refresh-error","Refresh completed with errors",{errors:e.errors}))},()=>{this._queryEngine.featureStore.clear()}),await this._waitSnapshotComplete(),{extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _snapshotFeatures(e){const t=e?.signal,n=this._maxTotalRecordCount,r=this._maxPageCount,o=this._supportsPagination&&r>1?await(0,h.E)(this._getFeatureUrl,this._featureType.typeName,{customParameters:this._customParameters,signal:t}):void 0;let i=[];const u=[];if(null==o)try{i=await this._singleQuery(t)}catch(e){(0,s.zf)(e)||u.push(e)}else{const e=Math.min(o,n),l=function*(e,t,n){for(let r=0;r<t;r++)yield e._pageQuery(r,n)}(this,(0,a.qE)(Math.ceil(e/this._maxRecordCount),1,r),t);await Promise.allSettled(Array.from({length:10}).map(()=>async function(e,t,n){let r=e.next();for(;!r.done;){try{const e=await r.value;t.push(...e)}catch(e){(0,s.zf)(e)||n.push(e)}r=e.next()}}(l,i,u)))}return(0,s.Te)(t),{features:i,totalRecordCount:o,maxTotalRecordCount:n,maxPageCount:r,errors:u}}async _singleQuery(e){const t=Number.isFinite(this._maxRecordCount)&&this._maxRecordCount>0?this._maxRecordCount:void 0,n=await(0,h.x$)(this._getFeatureUrl,this._featureType.typeName,this._getFeatureSpatialReference,this._getFeatureOutputFormat,{customParameters:this._customParameters,count:t,signal:e});return this._processGeoJSON(n,{signal:e})}async _pageQuery(e,t){const n=e*this._maxRecordCount,r=await(0,h.x$)(this._getFeatureUrl,this._featureType.typeName,this._getFeatureSpatialReference,this._getFeatureOutputFormat,{customParameters:this._customParameters,startIndex:n,count:this._maxRecordCount,signal:t});return this._processGeoJSON(r,{startIndex:n,signal:t})}_processGeoJSON(e,t){(0,m.sO)(e,this._getFeatureSpatialReference.wkid);const{startIndex:n,signal:r}=t;(0,s.Te)(r);const o=(0,m.bd)(e,{geometryType:this._geometryType,hasZ:!1,objectIdField:this._objectIdField});if(!(0,l.aI)(this._spatialReference,this._getFeatureSpatialReference))for(const e of o)null!=e.geometry&&(e.geometry=(0,c.Ux)((0,y.Cv)((0,c.zv)(e.geometry,this._geometryType,!1,!1),this._getFeatureSpatialReference,this._spatialReference)));let i=n??1;for(const e of o){const t={};(0,g.MB)(this._fieldsIndex,t,e.attributes,!0),e.attributes=t,null==t[this._objectIdField]&&(e.objectId=t[this._objectIdField]=i++)}return o}}function S(e){const t=[];return null!=e.totalRecordCount&&(e.features.length<e.totalRecordCount&&t.push({name:"wfs-layer:maxRecordCount-too-low",message:`Could only fetch ${e.features.length} of ${e.totalRecordCount} in ${e.maxPageCount} queries. Try increasing the value of WFSLayer.maxRecordCount.`,details:{recordCount:e.features.length,totalRecordCount:e.totalRecordCount}}),e.totalRecordCount>e.maxTotalRecordCount&&t.push({name:"wfs-layer:large-dataset",message:`The number of ${e.totalRecordCount} features exceeds the maximum allowed of ${e.maxTotalRecordCount}.`,details:{recordCount:e.features.length,totalRecordCount:e.totalRecordCount,maxTotalRecordCount:e.maxTotalRecordCount}})),t}},34322:(e,t,n)=>{n.d(t,{E:()=>L,Fu:()=>E,O8:()=>G,UH:()=>z,YW:()=>O,i5:()=>b,mG:()=>I,x$:()=>D});var r=n(78888),o=n(49186),i=n(5479),a=n(84952),s=n(5443),u=n(98988),l=n(16930),c=n(21325),p=n(50498),d=n(85113),y=n(13043),f=n(60694),m=n(20437),g=n(30524);const h="xlink:href",w="2.0.0",b="__esri_wfs_id__",C="wfs-layer:getWFSLayerTypeInfo-error",T="wfs-layer:empty-service",x="wfs-layer:feature-type-not-found",S="wfs-layer:geojson-not-supported",_="wfs-layer:kvp-encoding-not-supported",F="wfs-layer:malformed-json",R="wfs-layer:unknown-geometry-type",A="wfs-layer:unknown-field-type",v="wfs-layer:unsupported-spatial-reference",P="wfs-layer:unsupported-wfs-version";async function E(e,t){const n=function(e){const t=Z(e);(function(e){const t=e.firstElementChild?.getAttribute("version");if(t&&t!==w)throw new o.A(P,`Unsupported WFS version ${t}. Supported version: ${w}`)})(t),B(t);const n=t.firstElementChild,r=(0,i.PP)(function(e){return(0,y.i)(e,{FeatureTypeList:{FeatureType:e=>{const t={typeName:"undefined:undefined",name:"",title:"",description:"",extent:null,namespacePrefix:"",namespaceUri:"",defaultSpatialReference:4326,supportedSpatialReferences:[]},n=new Set;return(0,y.p)(e,{Name:e=>{const{name:n,prefix:r}=J(e.textContent);t.typeName=`${r}:${n}`,t.name=n,t.namespacePrefix=r,t.namespaceUri=e.lookupNamespaceURI(r)},Abstract:e=>{t.description=e.textContent},Title:e=>{t.title=e.textContent},WGS84BoundingBox:e=>{t.extent=s.A.fromJSON(function(e){let t,n,r,o;for(const i of e.children)switch(i.localName){case"LowerCorner":[t,n]=i.textContent.split(" ").map(e=>Number.parseFloat(e));break;case"UpperCorner":[r,o]=i.textContent.split(" ").map(e=>Number.parseFloat(e))}return{xmin:t,ymin:n,xmax:r,ymax:o,spatialReference:c.KK}}(e))},DefaultCRS:e=>{const r=j(e);r&&(t.defaultSpatialReference=r,n.add(r))},OtherCRS:e=>{const t=j(e);t&&n.add(t)}}),t.title||(t.title=t.name),n.add(4326),t.supportedSpatialReferences.push(...n),t}}})}(n));return{operations:M(n),get featureTypes(){return Array.from(r())},readFeatureTypes:r}}((await(0,r.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetCapabilities",VERSION:w,...t?.customParameters},signal:t?.signal})).data);return function(e,t){(0,a.m3)(e)&&((0,a.FX)(e,t.operations.DescribeFeatureType.url,!0)&&(t.operations.DescribeFeatureType.url=(0,a.lM)(t.operations.DescribeFeatureType.url)),(0,a.FX)(e,t.operations.GetFeature.url,!0)&&(t.operations.GetFeature.url=(0,a.lM)(t.operations.GetFeature.url)))}(e,n),n}const N=["json","application/json; subtype=geojson; charset=utf-8","application/json; subtype=geojson","application/json","geojson","application/geo+json"];function k(e){for(const t of N){const n=e.findIndex(e=>e.toLowerCase()===t);if(n>=0)return e[n]}return null}function M(e){let t=!0;const n={GetCapabilities:{url:""},DescribeFeatureType:{url:""},GetFeature:{url:"",outputFormat:null,supportsPagination:!1}},r=[],i=[];if((0,y.p)(e,{OperationsMetadata:{Parameter:e=>{if("outputformat"===e.getAttribute("name")?.toLowerCase())return{AllowedValues:{Value:({textContent:e})=>{e&&r.push(e)}}}},Operation:e=>{switch(e.getAttribute("name")){case"GetCapabilities":return{DCP:{HTTP:{Get:e=>{n.GetCapabilities.url=e.getAttribute(h)}}}};case"DescribeFeatureType":return{DCP:{HTTP:{Get:e=>{n.DescribeFeatureType.url=e.getAttribute(h)}}}};case"GetFeature":return{DCP:{HTTP:{Get:e=>{n.GetFeature.url=e.getAttribute(h)}}},Parameter:e=>{if("outputformat"===e.getAttribute("name")?.toLowerCase())return{AllowedValues:{Value:({textContent:e})=>{e&&i.push(e)}}}}}}},Constraint:e=>{switch(e.getAttribute("name")){case"KVPEncoding":return{DefaultValue:e=>{t="true"===e.textContent.toLowerCase()}};case"ImplementsResultPaging":return{DefaultValue:e=>{n.GetFeature.supportsPagination="true"===e.textContent.toLowerCase()}}}}}}),n.GetFeature.outputFormat=k(i)??k(r),!t)throw new o.A(_,"WFS service doesn't support key/value pair (KVP) encoding");if(null==n.GetFeature.outputFormat)throw new o.A(S,"WFS service doesn't support GeoJSON output format");return n}function j(e){const t=parseInt(e.textContent?.match(/(?<wkid>\d+$)/i)?.groups?.wkid??"",10);if(!Number.isNaN(t))return t}function I(e,t,n){return(0,i.I6)(e,e=>n?e.name===t&&e.namespaceUri===n:e.typeName===t||e.name===t)}async function G(e,t,n,r={}){const{featureType:i,extent:a}=await async function(e,t,n,r={}){const i=e.readFeatureTypes(),a=t?I(i,t,n):i.next().value,{spatialReference:s=new l.A({wkid:a?.defaultSpatialReference})}=r;if(null==a)throw t?new o.A(x,`The type '${t}' could not be found in the service`):new o.A(T,"The service is empty");let p=a.extent;if(p&&!(0,c.aI)(p.spatialReference,s))try{await(0,u.initializeProjection)(p.spatialReference,s,void 0,r),p=(0,u.project)(p,s)}catch{throw new o.A(v,"Projection not supported")}return{extent:p,spatialReference:s,featureType:a}}(e,t,n,r),{spatialReference:s}=z(e.operations.GetFeature.url,i,r.spatialReference),{fields:p,geometryType:d,swapXY:y,objectIdField:f,geometryField:m}=await async function(e,t,n,r={}){const{typeName:i}=t,[a,s]=await Promise.allSettled([q(e.operations.DescribeFeatureType.url,i,r),V(e,i,n,r)]),u=e=>new o.A(C,`An error occurred while getting info about the feature type '${i}'`,{error:e});if("rejected"===a.status)throw u(a.reason);if("rejected"===s.status)throw u(s.reason);const{fields:l,errors:c}=a.value??{},p=a.value?.geometryType||s.value?.geometryType,d=s.value?.swapXY??!1;if(null==p)throw new o.A(R,`The geometry type could not be determined for type '${i}`,{typeName:i,geometryType:p,fields:l,errors:c});return{...O(l??[]),geometryType:p,swapXY:d}}(e,i,s,r);return{url:e.operations.GetCapabilities.url,name:i.name,namespaceUri:i.namespaceUri,fields:p,geometryField:m,geometryType:d,objectIdField:f,spatialReference:r.spatialReference??new l.A({wkid:i.defaultSpatialReference}),extent:a,swapXY:y,wfsCapabilities:e,customParameters:r.customParameters}}function O(e){const t=e.find(e=>"geometry"===e.type);let n=e.find(e=>"oid"===e.type);return e=e.filter(e=>"geometry"!==e.type),n||(n=new m.A({name:b,type:"oid",alias:b}),e.unshift(n)),{geometryField:t?.name??null,objectIdField:n.name,fields:e}}async function V(e,t,n,o={}){let i,a=!1;const[s,u]=await Promise.all([D(e.operations.GetFeature.url,t,n,e.operations.GetFeature.outputFormat,{...o,count:1}),(0,r.A)(e.operations.GetFeature.url,{responseType:"text",query:U(t,n,void 0,{...o,count:1}),signal:o?.signal})]),l="FeatureCollection"===s.type&&s.features[0]?.geometry;if(l){let e;switch(i=p.gy.fromJSON((0,d.xD)(l.type)),l.type){case"Point":e=l.coordinates;break;case"LineString":case"MultiPoint":e=l.coordinates[0];break;case"MultiLineString":case"Polygon":e=l.coordinates[0][0];break;case"MultiPolygon":e=l.coordinates[0][0][0]}const t=/<[^>]*pos[^>]*> *(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/.exec(u.data);if(t){const n=e[0].toFixed(3),r=e[1].toFixed(3),o=parseFloat(t[1]).toFixed(3);n===parseFloat(t[2]).toFixed(3)&&r===o&&(a=!0)}}return{geometryType:i,swapXY:a}}async function q(e,t,n){return function(e,t){const{name:n}=J(e),r=Z(t);B(r);const a=(0,i.I6)((0,y.i)(r.firstElementChild,{element:e=>e}),e=>e.getAttribute("name")===n);if(null!=a){const e=a.getAttribute("type"),t=e?(0,i.I6)((0,y.i)(r.firstElementChild,{complexType:e=>e}),t=>t.getAttribute("name")===J(e).name):(0,i.I6)((0,y.i)(a,{complexType:e=>e}),()=>!0);if(t)return function(e){const t=[],n=[];let r;const i=(0,y.i)(e,{complexContent:{extension:{sequence:{element:e=>e}}}});for(const a of i){const i=a.getAttribute("name");if(!i)continue;let s,u;if(a.hasAttribute("type")?s=J(a.getAttribute("type")).name:(0,y.p)(a,{simpleType:{restriction:e=>(s=J(e.getAttribute("base")).name,{maxLength:e=>{u=+e.getAttribute("value")}})}}),!s)continue;const l="true"===a.getAttribute("nillable");let c=!1;switch(s.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":n.push(new m.A({name:i,alias:i,type:"integer",nullable:l,length:(0,g._b)("integer")}));break;case"float":case"double":case"decimal":n.push(new m.A({name:i,alias:i,type:"double",nullable:l,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":n.push(new m.A({name:i,alias:i,type:"string",nullable:l,length:u??(0,g._b)("string")}));break;case"datetime":case"date":n.push(new m.A({name:i,alias:i,type:"date",nullable:l,length:u??(0,g._b)("date")}));break;case"pointpropertytype":r="point",c=!0;break;case"multipointpropertytype":r="multipoint",c=!0;break;case"curvepropertytype":case"multicurvepropertytype":case"multilinestringpropertytype":r="polyline",c=!0;break;case"surfacepropertytype":case"multisurfacepropertytype":case"multipolygonpropertytype":r="polygon",c=!0;break;case"geometrypropertytype":case"multigeometrypropertytype":c=!0,t.push(new o.A(R,`geometry type '${s}' is not supported`,{type:(new XMLSerializer).serializeToString(e)}));break;default:t.push(new o.A(A,`Unknown field type '${s}'`,{type:(new XMLSerializer).serializeToString(e)}))}c&&n.push(new m.A({name:i,alias:i,type:"geometry",nullable:l}))}for(const e of n)if("integer"===e.type&&!e.nullable&&$.has(e.name.toLowerCase())){e.type="oid";break}return{geometryType:r,fields:n,errors:t}}(t)}throw new o.A(x,`Type '${e}' not found in document`,{document:(new XMLSerializer).serializeToString(r)})}(t,(await(0,r.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"DescribeFeatureType",VERSION:w,TYPENAME:t,TYPENAMES:t,...n?.customParameters},signal:n?.signal})).data)}const $=new Set(["objectid","fid"]);async function D(e,t,n,i,a){let{data:s}=await(0,r.A)(e,{responseType:"text",query:U(t,n,i,a),signal:a?.signal});s=s.replaceAll(/": +(-?\d+),(\d+)(,)?/g,'": $1.$2$3');try{return JSON.parse(s)}catch(e){throw new o.A(F,"Error while parsing the response",{response:s,error:e})}}function U(e,t,n,r){const o="number"==typeof t?t:t.wkid;return{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:w,TYPENAMES:e,OUTPUTFORMAT:n,SRSNAME:"EPSG:"+o,STARTINDEX:r?.startIndex,COUNT:r?.count,...r?.customParameters}}async function L(e,t,n){const o=await(0,r.A)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:w,TYPENAMES:t,RESULTTYPE:"hits",...n?.customParameters},signal:n?.signal}),i=/numberMatched=["'](?<numberMatched>\d+)["']/gi.exec(o.data);if(i?.groups)return+i.groups.numberMatched}function Z(e){return(new DOMParser).parseFromString(e.trim(),"text/xml")}function J(e){const[t,n]=e.split(":");return{prefix:n?t:"",name:n??t}}function B(e){let t="",n="";if((0,y.p)(e.firstElementChild,{Exception:e=>(t=e.getAttribute("exceptionCode"),{ExceptionText:e=>{n=e.textContent}})}),t)throw new o.A(`wfs-layer:${t}`,n)}function z(e,t,n){const r={wkid:t.defaultSpatialReference},o=null!=n?.wkid?{wkid:n.wkid}:r;return{spatialReference:o,getFeatureSpatialReference:(0,f.Fi)(e)||o.wkid&&t.supportedSpatialReferences.includes(o.wkid)?{wkid:o.wkid}:{wkid:t.defaultSpatialReference}}}},39357:(e,t,n)=>{n.d(t,{H:()=>u});var r,o=n(31635),i=n(25482),a=n(10107),s=(n(44208),n(53966),n(87811),n(40608));let u=r=class extends i.o{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,o.Cg)([(0,a.MZ)({type:String,json:{write:{isRequired:!0}}})],u.prototype,"name",void 0),(0,o.Cg)([(0,a.MZ)({type:[String,Number],json:{write:{isRequired:!0}}})],u.prototype,"code",void 0),u=r=(0,o.Cg)([(0,s.$)("esri.layers.support.CodedValue")],u)},50498:(e,t,n)=>{n.d(t,{Ye:()=>p,gy:()=>c,yR:()=>d});var r=n(66552),o=n(5443),i=n(91075),a=n(48526),s=n(86738),u=n(39829),l=n(82799);const c=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),p=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),d={base:i.A,key:"type",typeMap:{extent:o.A,multipoint:a.A,point:s.A,polyline:l.A,polygon:u.A}}},53177:(e,t,n)=>{n.d(t,{A:()=>p});var r,o=n(31635),i=n(4718),a=n(10107),s=(n(44208),n(53966),n(93223)),u=n(40608),l=n(39357),c=n(76357);let p=class extends c.A{static{r=this}constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some(e=>(String(e.code)===n&&(t=e.name),!!t))}return t}clone(){return new r({codedValues:(0,i.o8)(this.codedValues),name:this.name})}};(0,o.Cg)([(0,a.MZ)({type:[l.H],json:{write:{isRequired:!0}}})],p.prototype,"codedValues",void 0),(0,o.Cg)([(0,s.e)({codedValue:"coded-value"})],p.prototype,"type",void 0),p=r=(0,o.Cg)([(0,u.$)("esri.layers.support.CodedValueDomain")],p)},60999:(e,t,n)=>{n.d(t,{DZ:()=>f,Ke:()=>y,Tj:()=>c,UT:()=>m,jJ:()=>l});var r=n(31635),o=n(65008),i=n(97768),a=n(74887),s=n(10107),u=n(40608);function l(e,t,n){return(0,a.Lx)(e.map((e,r)=>t.apply(n,[e,r])))}async function c(e,t,n){return(await(0,a.Lx)(e.map((e,r)=>t.apply(n,[e,r])))).map(e=>e.value)}function p(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function y(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return d(e)}}async function f(e){try{return p(await e)}catch(e){return(0,a.QP)(e),d(e)}}function m(e,t){return new g(e,t)}let g=class extends o.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,i.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then(e=>{this._result=p(e),this._cleanup()},e=>{this._result=d(e),this._cleanup()}),this._abortHandle=(0,a.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,i.xt)(this._abortHandle),this._abortController=null}};(0,r.Cg)([(0,s.MZ)()],g.prototype,"value",null),(0,r.Cg)([(0,s.MZ)()],g.prototype,"error",null),(0,r.Cg)([(0,s.MZ)()],g.prototype,"finished",null),(0,r.Cg)([(0,s.MZ)()],g.prototype,"promise",void 0),(0,r.Cg)([(0,s.MZ)()],g.prototype,"_result",void 0),g=(0,r.Cg)([(0,u.$)("esri.core.asyncUtils.ReactiveTask")],g)},67482:(e,t,n)=>{function r(e){return null!=s(e)||null!=a(e)}function o(e){return u.test(e)}function i(e){return s(e)??a(e)}function a(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,r=0;for(;!t&&r<=e.length;)t=!l.test(e[r]),r++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function s(e){const t=u.exec(e);if(!t?.groups)return null;const n=t.groups,r=+n.year,o=+n.month-1,i=+n.day,a=+(n.hours??"0"),s=+(n.minutes??"0"),l=+(n.seconds??"0");if(a>23)return null;if(s>59)return null;if(l>59)return null;const c=n.ms??"0",p=c?+c.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(r,o,i,a,s,l,p);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(r,o,i,a,s,l,p)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>o,Cq:()=>r,_U:()=>i});const u=/^(?:(?<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})))?$/,l=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},76357:(e,t,n)=>{n.d(t,{A:()=>c});var r=n(31635),o=n(66552),i=n(25482),a=n(10107),s=(n(44208),n(53966),n(87811),n(93223)),u=n(40608);const l=new o.J({inherited:"inherited",codedValue:"coded-value",range:"range"});let c=class extends i.o{constructor(e){super(e),this.name=null,this.type=null}};(0,r.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,r.Cg)([(0,s.e)(l),(0,a.MZ)({json:{write:{isRequired:!0}}})],c.prototype,"type",void 0),c=(0,r.Cg)([(0,u.$)("esri.layers.support.Domain")],c)},80451:(e,t,n)=>{n.d(t,{rS:()=>f,gK:()=>y}),n(44208);var r,o=n(53177),i=n(76357),a=n(31635),s=(n(53966),n(87811),n(49186),n(93223)),u=n(40608);let l=class extends i.A{static{r=this}constructor(e){super(e),this.type="inherited"}clone(){return new r}};(0,a.Cg)([(0,s.e)({inherited:"inherited"})],l.prototype,"type",void 0),l=r=(0,a.Cg)([(0,u.$)("esri.layers.support.InheritedDomain")],l);var c,p=n(10107);let d=class extends i.A{static{c=this}constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new c({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,a.Cg)([(0,p.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]},isRequired:!0}}})],d.prototype,"maxValue",void 0),(0,a.Cg)([(0,p.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]},isRequired:!0}}})],d.prototype,"minValue",void 0),(0,a.Cg)([(0,s.e)({range:"range"})],d.prototype,"type",void 0),d=c=(0,a.Cg)([(0,u.$)("esri.layers.support.RangeDomain")],d);const y={key:"type",base:i.A,typeMap:{range:d,"coded-value":o.A,inherited:l}};function f(e){if(!e?.type)return null;switch(e.type){case"range":return d.fromJSON(e);case"codedValue":return o.A.fromJSON(e);case"inherited":return l.fromJSON(e)}return null}},82832:(e,t,n)=>{n.d(t,{$1:()=>g,CR:()=>m,MB:()=>d,PC:()=>h,Yx:()=>u,bP:()=>c});var r=n(67482),o=n(21325),i=n(30524);class a{constructor(e){this.description=e,this.code=null}}class s{constructor(e){this.globalId=null,this.objectId=null,this.success=!1,this.uniqueId=null,this.error=new a(e)}}function u(e){return new s(e)}class l{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function c(e){return new l(e)}const p=new Set;function d(e,t,n,r=!1){p.clear();for(const o in n){const a=e.get(o);if(!a)continue;const s=y(a,n[o]);if(p.add(a.name),a&&(r||a.editable)){const e=(0,i.CJ)(a,s);if(e)return u((0,i.uo)(e,a,s));t[a.name]=s}}for(const t of e.requiredFields??[])if(!p.has(t.name))return u(`missing required field "${t.name}"`);return null}function y(e,t){let n=t;return(0,i.WA)(e)&&"string"==typeof t?n=parseFloat(t):(0,i.yM)(e)&&null!=t&&"string"!=typeof t?n=String(t):(0,i.vE)(e)&&"string"==typeof t&&(n=(0,r._U)(t)),(0,i.WX)(n)}let f;function m(e,t){if(!e||!(0,o.fn)(t))return e;if("rings"in e||"paths"in e){if(null==f)throw new TypeError("geometry engine not loaded");return f.simplify(t,e)}return e}async function g(e,t){!(0,o.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==f&&(f=await Promise.all([n.e(9930),n.e(7559)]).then(n.bind(n,47559))),f}()}const h={supportsAutoIntervalBin:!0,supportsFixedIntervalBin:!0,supportsFixedBoundariesBin:!0,supportsDateBin:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsNormalization:!0,supportedStatisticTypes:["COUNT","SUM","AVG","VAR","STDDEV","MIN","MAX","PERCENTILE_CONT","PERCENTILE_DISC","CentroidAggregate","EnvelopeAggregate","ConvexHullAggregate"],supportedNormalizationTypes:["field","log","naturalLog","percentOfTotal","squareRoot"]}},85113:(e,t,n)=>{n.d(t,{BM:()=>_,bd:()=>F,sO:()=>S,xD:()=>c});var r=n(67482),o=n(49186),i=n(21325),a=n(43334),s=n(92722),u=n(30524);const l={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function c(e){return l[e]}function*p(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*d(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(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function y(e){for(const t of e)if(t.length>2)return!0;return!1}function f(e){let t=0;for(let n=0;n<e.length;n++){const r=e[n],o=e[(n+1)%e.length];t+=r[0]*o[1]-o[0]*r[1]}return t<=0}function m(e){const t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t),e}function g(e,t,n){switch(t.type){case"LineString":case"MultiPoint":return function(e,t,n){return b(e,t.coordinates,n),e}(e,t,n);case"MultiLineString":return function(e,t,n){for(const r of t.coordinates)b(e,r,n);return e}(e,t,n);case"MultiPolygon":return function(e,t,n){for(const r of t.coordinates){h(e,r[0],n);for(let t=1;t<r.length;t++)w(e,r[t],n)}return e}(e,t,n);case"Point":return function(e,t,n){return T(e,t.coordinates,n),e}(e,t,n);case"Polygon":return function(e,t,n){const r=t.coordinates;h(e,r[0],n);for(let t=1;t<r.length;t++)w(e,r[t],n);return e}(e,t,n)}}function h(e,t,n){const r=m(t);!function(e){return!f(e)}(r)?b(e,r,n):C(e,r,n)}function w(e,t,n){const r=m(t);!function(e){return f(e)}(r)?b(e,r,n):C(e,r,n)}function b(e,t,n){for(const r of t)T(e,r,n);e.lengths.push(t.length)}function C(e,t,n){for(let r=t.length-1;r>=0;r--)T(e,t[r],n);e.lengths.push(t.length)}function T(e,t,n){const[r,o,i]=t;e.coords.push(r,o),n.hasZ&&e.coords.push(i||0)}function x(e){switch(typeof e){case"string":return(0,r.Br)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function S(e,t=4326){if(!e)throw new o.A("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new o.A("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:n}=e;if(!n)return;const r="string"==typeof n?n:"name"===n.type?n.properties.name:"EPSG"===n.type?n.properties.code:null,a=(0,i.oT)({wkid:t})?new RegExp(".*(CRS84H?|4326)$","i"):new RegExp(`.*(${t})$`,"i");if(!r||!a.test(r))throw new o.A("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:n})}function _(e,t={}){const n=[],r=new Set,o=new Set;let i,a=!1,s=null,l=!1,{geometryType:f=null}=t;for(const t of p(e)){const{geometry:e,properties:p,id:m}=t;if((!e||(f||(f=c(e.type)),c(e.type)===f))&&(a||(a=y(d(e))),l||(l=null!=m,l&&(i=typeof m,p&&(s=Object.keys(p).filter(e=>p[e]===m)))),p&&s&&l&&null!=m&&(s.length>1?s=s.filter(e=>p[e]===m):1===s.length&&(s=p[s[0]]===m?s:[])),p))for(const e in p){if(r.has(e))continue;const t=x(p[e]);if("unknown"===t){o.add(e);continue}o.delete(e),r.add(e);const i=(0,u.rS)(e);i&&n.push({name:i,alias:e,type:t})}}const m=(0,u.rS)(1===s?.length&&s[0]||null)??void 0;if(m)for(const e of n)if(e.name===m&&(0,u.WA)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:f,hasZ:a,objectIdFieldName:m,objectIdFieldType:i,unknownFields:Array.from(o)}}function F(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:r}=t;for(const o of e){const{geometry:e,properties:i,id:u}=o;if(e&&c(e.type)!==n)continue;const l=i||{};let p;r&&(p=l[r],null==u||p||(l[r]=p=u));const d=new a.Om(e?g(new s.A,e,t):null,l,null,p);yield d}}(p(e),t))}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[752],{14607:(e,t,n)=>{n.d(t,{B:()=>u,GP:()=>l,qg:()=>c});var i=n(799),r=n(73444);const s={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],no:[","," "],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e=(0,r.JK)()){let t=(e=e.toLowerCase())in s;if(!t){const n=e.split("-");n.length>1&&n[0]in s&&(e=n[0],t=!0),t||(e="en")}const[n,i,o="#,##0.###"]=s[e];return{decimal:n,group:i,pattern:o}}function l(e,t){const n=o((t={...t}).locale);t.customs=n;const i=t.pattern||n.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,n){const i=(n=n||{}).customs.group,r=n.customs.decimal,s=t.split(";"),o=s[0];if((t=s[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const l=a,u=o.match(l);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===n.fractional&&(n.places=0),t.replace(l,function(e,t,n){!0===(n=n||{}).places&&(n.places=0),n.places===1/0&&(n.places=6);const i=t.split("."),r="string"==typeof n.places&&n.places.indexOf(",");let s=n.places;r?s=n.places.slice(r+1):+s>=0||(s=(i[1]||[]).length),n.round<0||(e=Number(e.toFixed(Number(s))));const o=String(Math.abs(e)).split("."),l=o[1]||"";if(i[1]||n.places){r&&(n.places=n.places.slice(0,Math.max(0,r)));const e=void 0!==n.places?n.places:i[1]&&i[1].lastIndexOf("0")+1;+e>l.length&&(o[1]=l.padEnd(Number(e),"0")),+s<l.length&&(o[1]=l.slice(0,Math.max(0,Number(s))))}else o[1]&&o.pop();const a=i[0].replace(",","");let u=a.indexOf("0");-1!==u&&(u=a.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),a.includes("#")||(o[0]=o[0].slice(-u)));let c,p,d=i[0].lastIndexOf(",");if(-1!==d){c=i[0].length-d-1;const e=i[0].slice(0,d);d=e.lastIndexOf(","),-1!==d&&(p=e.length-d-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.slice(Math.max(0,t)):e),e=t>0?e.slice(0,t):"",p&&(c=p,p=void 0)}return o[0]=f.reverse().join(n.group||","),o.join(n.decimal||".")}(e,u[0],{decimal:r,group:i,places:n.places,round:n.round}))}(e,i,t)}const a=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),n=e.pattern||t.pattern,r=t.group,s=t.decimal;let l=1;if(n.includes("%"))l/=100;else if(n.includes("‰"))l/=1e3;else if(n.includes("¤"))throw new Error("currency notation not supported");const u=n.split(";");1===u.length&&u.push("-"+u[0]);const c=d(u,t=>(t="(?:"+(0,i.Cj)(t,".")+")").replace(a,t=>{const n={signed:!1,separator:e.strict?r:[r,""],fractional:e.fractional,decimal:s,exponent:!1},i=t.split(".");let o=e.places;1===i.length&&1!==l&&(i[1]="###"),1===i.length||0===o?n.fractional=!1:(void 0===o&&(o=e.pattern?i[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(n.fractional=!0),!e.places&&+o<i[1].length&&(o+=","+i[1].length),n.places=o);const a=i[0].split(",");return a.length>1&&(n.groupSize=a.pop().length,a.length>1&&(n.groupSize2=a.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!String(e.places).startsWith("0")||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=p(e),n=d(e.fractional,t=>{let n="";return t&&0!==e.places&&(n="\\"+e.decimal,e.places===1/0?n="(?:"+n+"\\d+)?":n+="\\d{"+e.places+"}"),n},!0);let i=t+n;return n&&(i="(?:(?:"+i+")|(?:"+n+"))"),i+d(e.exponent,t=>t?"([eE]"+p({signed:e.eSigned})+")":"")}(n)+")"}),!0);return{regexp:c.replaceAll(/[\xa0 ]/g,"[\\s\\xa0]"),group:r,decimal:s,factor:l}}function c(e,t){const n=u(t),i=new RegExp("^"+n.regexp+"$").exec(e);if(!i)return NaN;let r=i[1];if(!i[1]){if(!i[2])return NaN;r=i[2],n.factor*=-1}return r=r.replaceAll(new RegExp("["+n.group+"\\s\\xa0]","g"),"").replace(n.decimal,"."),Number(r)*n.factor}function p(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",d(e.signed,e=>e?"[-+]":"",!0)+d(e.separator,t=>{if(!t)return"(?:\\d+)";" "===(t=(0,i.Cj)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const n=e.groupSize,r=e.groupSize2;if(r){const e="(?:0|[1-9]\\d{0,"+(r-1)+"}(?:["+t+"]\\d{"+r+"})*["+t+"]\\d{"+n+"})";return n-r>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(n-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(n-1)+"}(?:["+t+"]\\d{"+n+"})*)"},!0)}const d=(e,t,n)=>{if(!Array.isArray(e))return t(e);const i=[];for(let n=0;n<e.length;n++)i.push(t(e[n]));return f(i.join("|"),Boolean(n))},f=(e,t)=>"("+(t?"?:":"")+e+")"},40752:(e,t,n)=>{n.r(t),n.d(t,{default:()=>H});var i=n(78888),r=n(60999),s=n(67482),o=n(49186),l=n(53966),a=n(74887),u=n(84952),c=n(98988),p=n(16930),d=n(7320),f=n(21325),h=n(28735),m=n(43334),y=n(92722),g=n(58376),S=n(83221),_=n(31464),b=n(95422),w=n(14607),x=n(30524);function N(e,t,n){t=(0,x.rS)(t)?.toLowerCase(),n=(0,x.rS)(n)?.toLowerCase();const i=e.map(e=>e.toLowerCase()),r=t?e[i.indexOf(t)]:null,s=n?e[i.indexOf(n)]:null;return{longitudeFieldName:r||e[i.indexOf(I.find(e=>i.includes(e)))],latitudeFieldName:s||e[i.indexOf(F.find(e=>i.includes(e)))]}}const F=["lat","lat83","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],I=["lon","lng","lng83","long","long83","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"],C=/^\s*"([\S\s]*)"\s*$/,T=/""/g,E=[","," ",";","|","\t"];function*A(e,t,n){let i=0;for(;i<=e.length;){const r=e.indexOf(t,i),s=e.slice(i,r>-1?r:void 0);i+=s.length+t.length,n&&!s.trim()||(yield s)}}function v(e){const t=e.includes("\r\n")?"\r\n":"\n";return A(e,t,!0)}function O(e,t){return A(e,t,!1)}function k(e,t,n){e=e.trim(),t=t?.trim();const i=[],r=Array.from(new Set([n?.delimiter,...E])).filter(e=>null!=e);for(const n of r){const r=M(e,n).length,s=M(t,n).length??r;r>1&&i.push({weight:Math.min(r,s),delimiter:n})}const s=i.sort(({weight:e},{weight:t})=>t-e).map(({delimiter:e})=>e);for(const t of s){const i=N(D(e,t).names,n?.longitudeField,n?.latitudeField);if(i.longitudeFieldName&&i.latitudeFieldName)return{delimiter:t,locationInfo:i}}return{delimiter:s[0],locationInfo:null}}function*q(e,t,n,i=()=>Object.create(null)){const r=v(e);r.next();let s="",o="",l=0,a=i(),u=0;e:for(const e of r){const r=O(e,n);for(const e of r)if(s+=o+e,o="",l+=j(e),l%2==0){if(l>0){const e=C.exec(s);if(!e){a=i(),u=0,s="",l=0;continue e}a[t[u]]=e[1].replaceAll(T,'"'),u++}else a[t[u]]=s,u++;s="",l=0}else o=n;0===l?(yield a,a=i(),u=0):o="\n"}}function D(e,t){const n=M(e,t).filter(e=>null!=e),i=n.map(e=>(0,x.rS)(e));for(let e=i.length-1;e>=0;e--)i[e]||(i.splice(e,1),n.splice(e,1));return{names:i,aliases:n}}function M(e,t){if(!e?.length)return[];const n=[];let i="",r="",s=0;const o=O(e,t);for(const e of o)if(i+=r+e,r="",s+=j(e),s%2==0){if(s>0){const e=C.exec(i);e&&n.push(e[1].replaceAll(T,'"'))}else n.push(i);i="",s=0}else r=t;return n}function j(e){let t=0,n=0;for(n=e.indexOf('"',n);n>=0;)t++,n=e.indexOf('"',n+1);return t}function R(e,t,n,i,r){const s=[],o=q(e,n,t),l=[];for(const e of o){if(10===l.length)break;l.push(e)}for(let e=0;e<n.length;e++){const t=n[e],o=i[e];if(t===r.longitudeFieldName||t===r.latitudeFieldName)s.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e;switch(L(l.map(e=>e[t]))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate";break;default:e="esriFieldTypeString"}s.push({name:t,type:e,alias:o,length:(0,x._b)(e)})}}return s}function L(e){if(!e.length)return"string";const t=/[^+\-.,0-9]/;return e.map(e=>{if(""!==e){if(!t.test(e)){let t=z(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!Number.isNaN(t))return"double";if(e.includes(",")&&(e=e.replace(",","."),t=Number(e),!Number.isNaN(t)))return"double"}}return(0,s.Cq)(e)?"date":"string"}}).reduce((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0)}const z=function(){const e=(0,w.B)(),t=new RegExp("^"+e.regexp+"$"),n=new RegExp("["+e.group+"\\s\\xa0]","g"),i=e.factor;return r=>{const s=t.exec(r);if(e.factor=i,!s)return NaN;let o=s[1];if(!s[1]){if(!s[2])return NaN;o=s[2],e.factor*=-1}return o=o.replace(n,"").replace(e.decimal,"."),+o*e.factor}}();function $(e){return JSON.parse(JSON.stringify(e))}var P=n(64714),U=n(95466),V=n(54218),B=n(98623);const Z=(0,P.F0)("esriGeometryPoint"),G=["csv"],Q=[0,0];class J{constructor(e,t){this.x=e,this.y=t}}class H{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[n]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),i=function(e,t){const n=t.parsingOptions||{},i={delimiter:n.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:n.latitudeField,longitudeFieldName:n.longitudeField}},r=i.layerDefinition={name:(0,u.e7)(t.url,G)||"csv",dateFieldsTimeReference:{timeZoneIANA:B.n$},drawingInfo:Z,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:n.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:n.spatialReference||{wkid:4326}}},s=v(e),l=s.next().value?.trim(),a=s.next().value?.trim();if(!l)throw new o.A("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:p}=k(l,a,n);if(!c)throw new o.A("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV",{firstLine:l,secondLine:a,parsingOptions:n});if(!p)throw new o.A("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file",{firstLine:l,secondLine:a,parsingOptions:n});i.locationInfo=p,i.delimiter=c;const{names:d,aliases:f}=D(l,c),h=R(e,i.delimiter,d,f,i.locationInfo);if(n.fields?.length){const e=new U.A(n.fields);for(const t of h){const n=e.get(t.name);n&&Object.assign(t,n)}}if(!h.some(e=>"esriFieldTypeOID"===e.type&&(r.objectIdField=e.name,!0))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};r.objectIdField=e.name,h.unshift(e)}r.fields=h;const m=new U.A(r.fields);if(i.locationInfo&&(i.locationInfo.latitudeFieldName=m.get(i.locationInfo.latitudeFieldName).name,i.locationInfo.longitudeFieldName=m.get(i.locationInfo.longitudeFieldName).name),r.timeInfo){const e=r.timeInfo;if(e.startTimeField){const t=m.get(e.startTimeField);t?(e.startTimeField=t.name,t.type="esriFieldTypeDate"):e.startTimeField=null}if(e.endTimeField){const t=m.get(e.endTimeField);t?(e.endTimeField=t.name,t.type="esriFieldTypeDate"):e.endTimeField=null}if(e.trackIdField){const t=m.get(e.trackIdField);e.trackIdField=t?t.name:null}e.startTimeField||e.endTimeField||(r.timeInfo=null)}return i}(n,e);this._locationInfo=i.locationInfo,this._delimiter=i.delimiter,this._queryEngine=this._createQueryEngine(i);const r=this._createFeatures(n);this._queryEngine.featureStore.addMany(r);const{fullExtent:s,timeExtent:l}=await this._queryEngine.fetchRecomputedExtents();if(i.layerDefinition.extent=s,l){const{start:e,end:t}=l;i.layerDefinition.timeInfo.timeExtent=[e,t]}return i}async applyEdits(){throw new o.A("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),(await this._queryEngine.executeQueryForIds(e,t.signal)).filter(V.Et)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),(0,g.J)(this._queryEngine,e,t.signal)}async queryAttributeBins(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeAttributeBinsQuery(e,t.signal)}async refresh(e){this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.UT)(this._snapshotFeatures),this._snapshotTask.promise.then(e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)},e=>{this._queryEngine.featureStore.clear(),(0,a.zf)(e)||l.A.getLogger("esri.layers.CSVLayer").error(new o.A("csv-layer:refresh","An error occurred during refresh",{error:e}))}),await this._waitSnapshotComplete();const{fullExtent:t,timeExtent:n}=await this._queryEngine.fetchRecomputedExtents();return{extent:t,timeExtent:n}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:n}=this._loadOptions;if(!t)throw new o.A("csv-layer:invalid-source","url not defined");const r=(0,u.An)(t);return(await(0,i.A)(r.path,{query:{...r.query,...n},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:n,extent:i,timeInfo:r}=e.layerDefinition,s=new S.A({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1}),o={type:"object-id",fieldName:t};return new b.do({fieldsIndex:U.A.fromLayerJSON({fields:n,dateFieldsTimeReference:{timeZoneIANA:B.n$}}),geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:r,featureIdInfo:o,spatialReference:i.spatialReference||{wkid:4326},featureStore:s})}_createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:n}=this._locationInfo,{objectIdField:i,fieldsIndex:r,spatialReference:o}=this._queryEngine;let l=[];const a=[],u=r.fields.filter(e=>e.name!==i).map(e=>e.name);let g=0;const S={};for(const e of r.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,x.lD)(e);void 0!==t&&(S[e.name]=t)}const _=q(e,u,this._delimiter,(0,P.Vx)(S,i));for(const e of _){const o=this._parseCoordinateValue(e[t]),u=this._parseCoordinateValue(e[n]);if(null!=u&&null!=o&&!isNaN(o)&&!isNaN(u)){e[t]=o,e[n]=u;for(const i in e)if(i!==t&&i!==n)if(r.isDateField(i))e[i]=(0,s._U)(e[i]);else if(r.isNumericField(i)){const t=z(e[i]);isNaN(t)?e[i]=null:e[i]=t}else null!=e[i]&&(e[i]=$(e[i]));e[i]=g,g++,l.push(new J(u,o)),a.push(e)}}if(!(0,f.aI)({wkid:4326},o))if((0,f.K8)(o))for(const e of l)[e.x,e.y]=(0,h.je)(e.x,e.y,Q);else l=(0,c.projectMany)(d.g,l,p.A.WGS84,o,null,null);const b=[];for(let e=0;e<l.length;e++){const{x:t,y:n}=l[e],r=a[e];r[i]=e+1,b.push(new m.Om(new y.A([],[t,n]),r,null,r[i]))}return b}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=z(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,_.Nk)(f.KK,e)}catch{throw new o.A("csv-layer:projection-not-supported","Projection not supported")}}}},60999:(e,t,n)=>{n.d(t,{DZ:()=>h,Ke:()=>f,Tj:()=>c,UT:()=>m,jJ:()=>u});var i=n(31635),r=n(65008),s=n(97768),o=n(74887),l=n(10107),a=n(40608);function u(e,t,n){return(0,o.Lx)(e.map((e,i)=>t.apply(n,[e,i])))}async function c(e,t,n){return(await(0,o.Lx)(e.map((e,i)=>t.apply(n,[e,i])))).map(e=>e.value)}function p(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function f(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return d(e)}}async function h(e){try{return p(await e)}catch(e){return(0,o.QP)(e),d(e)}}function m(e,t){return new y(e,t)}let y=class extends r.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;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then(e=>{this._result=p(e),this._cleanup()},e=>{this._result=d(e),this._cleanup()}),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,s.xt)(this._abortHandle),this._abortController=null}};(0,i.Cg)([(0,l.MZ)()],y.prototype,"value",null),(0,i.Cg)([(0,l.MZ)()],y.prototype,"error",null),(0,i.Cg)([(0,l.MZ)()],y.prototype,"finished",null),(0,i.Cg)([(0,l.MZ)()],y.prototype,"promise",void 0),(0,i.Cg)([(0,l.MZ)()],y.prototype,"_result",void 0),y=(0,i.Cg)([(0,a.$)("esri.core.asyncUtils.ReactiveTask")],y)},64714:(e,t,n)=>{n.d(t,{F0:()=>l,Vx:()=>c,e2:()=>d,f:()=>f});var i=n(44208),r=n(4718),s=n(99352),o=n(93470);function l(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const a=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,i.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${p(t)} = null;`;for(const t in e)n+=`this${p(t)} = ${JSON.stringify(e[t])};`;const i=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new i}catch(n){return()=>({[t]:null,...e})}}function p(e){return a.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function f(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},67482:(e,t,n)=>{function i(e){return null!=l(e)||null!=o(e)}function r(e){return a.test(e)}function s(e){return l(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,i=0;for(;!t&&i<=e.length;)t=!u.test(e[i]),i++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function l(e){const t=a.exec(e);if(!t?.groups)return null;const n=t.groups,i=+n.year,r=+n.month-1,s=+n.day,o=+(n.hours??"0"),l=+(n.minutes??"0"),u=+(n.seconds??"0");if(o>23)return null;if(l>59)return null;if(u>59)return null;const c=n.ms??"0",p=c?+c.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(i,r,s,o,l,u,p);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,r,s,o,l,u,p)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>r,Cq:()=>i,_U:()=>s});const a=/^(?:(?<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})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},93470:(e,t,n)=>{n.d(t,{Cb:()=>s,HW:()=>c,JR:()=>r,JZ:()=>a,WR:()=>l,b6:()=>p,fT:()=>i,nC:()=>u,yM:()=>o});const i=[252,146,31,255],r=[153,153,153,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},l={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={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},u={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},c={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},p={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4522],{10536:(e,t,s)=>{function r(e){const t={};for(const s in e){if("declaredClass"===s)continue;const i=e[s];if(null!=i&&"function"!=typeof i)if(Array.isArray(i)){t[s]=[];for(let e=0;e<i.length;e++)t[s][e]=r(i[e])}else"object"==typeof i?i.toJSON&&(t[s]=JSON.stringify(i)):t[s]=i}return t}s.d(t,{z:()=>r})},13069:(e,t,s)=>{s.d(t,{AG:()=>a,lk:()=>i,vD:()=>o,yS:()=>n});const r="randomUUID"in crypto;function i(){if(r)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function n(){return`{${i().toUpperCase()}}`}function o(){return`{${i()}}`}function a(e){const t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},20437:(e,t,s)=>{s.d(t,{A:()=>y});var r,i=s(31635),n=s(66552),o=s(25482),a=s(10107),l=s(56507),u=(s(44208),s(87811),s(93223)),d=s(36005),c=s(40608),p=s(80451),h=s(98453);const g=new n.J({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",currency:"currency",dateAndTime:"date-and-time",description:"description",emailAddress:"email-address",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",phoneNumber:"phone-number",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let y=class extends o.o{static{r=this}constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let s=null;try{s=t?JSON.parse(t):null}catch(e){}return s?.value??null}readValueType(e,{description:t}){let s=null;try{s=t?JSON.parse(t):null}catch(e){}return s?g.fromJSON(s.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain?.clone()??null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,i.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],y.prototype,"alias",void 0),(0,i.Cg)([(0,a.MZ)({type:[String,Number],json:{write:{allowNull:!0}}})],y.prototype,"defaultValue",void 0),(0,i.Cg)([(0,a.MZ)()],y.prototype,"description",void 0),(0,i.Cg)([(0,d.w)("description")],y.prototype,"readDescription",null),(0,i.Cg)([(0,a.MZ)({types:p.gK,json:{read:{reader:p.rS},write:!0}})],y.prototype,"domain",void 0),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"editable",void 0),(0,i.Cg)([(0,a.MZ)({type:l.jz,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],y.prototype,"length",void 0),(0,i.Cg)([(0,a.MZ)({type:String,json:{write:!0}})],y.prototype,"name",void 0),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{write:!0}})],y.prototype,"nullable",void 0),(0,i.Cg)([(0,u.e)(h.m)],y.prototype,"type",void 0),(0,i.Cg)([(0,a.MZ)()],y.prototype,"valueType",void 0),(0,i.Cg)([(0,d.w)("valueType",["description"])],y.prototype,"readValueType",null),(0,i.Cg)([(0,a.MZ)({type:Boolean,json:{read:!1}})],y.prototype,"visible",void 0),y=r=(0,i.Cg)([(0,c.$)("esri.layers.support.Field")],y)},39357:(e,t,s)=>{s.d(t,{H:()=>l});var r,i=s(31635),n=s(25482),o=s(10107),a=(s(44208),s(53966),s(87811),s(40608));let l=r=class extends n.o{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,i.Cg)([(0,o.MZ)({type:String,json:{write:{isRequired:!0}}})],l.prototype,"name",void 0),(0,i.Cg)([(0,o.MZ)({type:[String,Number],json:{write:{isRequired:!0}}})],l.prototype,"code",void 0),l=r=(0,i.Cg)([(0,a.$)("esri.layers.support.CodedValue")],l)},50498:(e,t,s)=>{s.d(t,{Ye:()=>c,gy:()=>d,yR:()=>p});var r=s(66552),i=s(5443),n=s(91075),o=s(48526),a=s(86738),l=s(39829),u=s(82799);const d=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),c=(0,r.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),p={base:n.A,key:"type",typeMap:{extent:i.A,multipoint:o.A,point:a.A,polyline:u.A,polygon:l.A}}},51624:(e,t,s)=>{s.d(t,{A:()=>u});var r=s(44208),i=s(69397),n=s(93687);const o=4294967296,a=new TextDecoder("utf-8"),l=(0,r.A)("safari")||(0,r.A)("ios")?6:(0,r.A)("ff")?12:32;class u{constructor(e,t,s=0,r=(e?e.byteLength:0)){this._tag=0,this._dataType=99,this._init(e,t,s,r)}_init(e,t,s,r){this._data=e,this._dataView=t,this._pos=s,this._end=r}get usedMemory(){return 64+(0,i.Qf)(this._data)}asUnsafe(){return this}clone(){return new u(this._data,this._dataView,this._pos,this._end)}pos(){return this._pos}move(e){this._pos=e}nextTag(e){for(;;){if(this._pos===this._end)return!1;const t=this._decodeVarint();if(this._tag=t>>3,this._dataType=7&t,!e||e===this._tag)break;this.skip()}return!0}next(){if(this._pos===this._end)return!1;const e=this._decodeVarint();return this._tag=e>>3,this._dataType=7&e,!0}empty(){return this._pos>=this._end}tag(){return this._tag}getInt32(){return this._decodeVarint()}getInt64(){return this._decodeVarint()}getUInt32(){let e=4294967295;if(e=(127&this._data[this._pos])>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<7)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<14)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<21)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(15&this._data[this._pos])<<28)>>>0,this._data[this._pos++]<128)return e;throw new Error("Varint overflow")}getUInt64(){return this._decodeVarint()}getSInt32(){const e=this.getUInt32();return e>>>1^-(1&e)}getSInt64(){return this._decodeSVarint()}getBool(){const e=0!==this._data[this._pos];return this._skip(1),e}getEnum(){return this._decodeVarint()}getFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getUint32(t+4,!0)*o;return this._skip(8),s}getSFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getInt32(t+4,!0)*o;return this._skip(8),s}getDouble(){const e=this._dataView.getFloat64(this._pos,!0);return this._skip(8),e}getFixed32(){const e=this._dataView.getUint32(this._pos,!0);return this._skip(4),e}getSFixed32(){const e=this._dataView.getInt32(this._pos,!0);return this._skip(4),e}getFloat(){const e=this._dataView.getFloat32(this._pos,!0);return this._skip(4),e}getString(){const e=this._getLength(),t=this._pos,s=this._toString(this._data,t,t+e);return this._skip(e),s}getBytes(){const e=this._getLength(),t=this._pos,s=this._toBytes(this._data,t,t+e);return this._skip(e),s}getLength(){return this._getLengthUnsafe()}processMessageWithArgs(e,t,s,r){const i=this.getMessage(),n=e(i,t,s,r);return i.release(),n}processMessage(e){const t=this.getMessage(),s=e(t);return t.release(),s}getMessage(){const e=this._getLength(),t=u.pool.acquire();return t._init(this._data,this._dataView,this._pos,this._pos+e),this._skip(e),t}release(){u.pool.release(this)}dataType(){return this._dataType}skip(){switch(this._dataType){case 0:this._decodeVarint();break;case 1:this._skip(8);break;case 2:this._skip(this._getLength());break;case 5:this._skip(4);break;default:throw new Error("Invalid data type!")}}skipLen(e){this._skip(e)}_skip(e){if(this._pos+e>this._end)throw new Error("Attempt to skip past the end of buffer!");this._pos+=e}_decodeVarint(){const e=this._data;let t=this._pos,s=0,r=0;if(this._end-t>=10)do{if(r=e[t++],s|=127&r,!(128&r))break;if(r=e[t++],s|=(127&r)<<7,!(128&r))break;if(r=e[t++],s|=(127&r)<<14,!(128&r))break;if(r=e[t++],s|=(127&r)<<21,!(128&r))break;if(r=e[t++],s+=268435456*(127&r),!(128&r))break;if(r=e[t++],s+=34359738368*(127&r),!(128&r))break;if(r=e[t++],s+=4398046511104*(127&r),!(128&r))break;if(r=e[t++],s+=562949953421312*(127&r),!(128&r))break;if(r=e[t++],s+=72057594037927940*(127&r),!(128&r))break;if(r=e[t++],s+=0x8000000000000000*(127&r),!(128&r))break;throw new Error("Varint too long!")}while(0);else{let i=1;for(;t!==this._end&&(r=e[t],128&r);)++t,s+=(127&r)*i,i*=128;if(t===this._end)throw new Error("Varint overrun!");++t,s+=r*i}return this._pos=t,s}_decodeSVarint(){const e=this._data;let t,s=0,r=0;const i=1&e[this._pos];if(r=e[this._pos++],s|=127&r,!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s|=(127&r)<<7,!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s|=(127&r)<<14,!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s|=(127&r)<<21,!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s+=268435456*(127&r),!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s+=34359738368*(127&r),!(128&r))return i?-(s+1)/2:s/2;if(r=e[this._pos++],s+=4398046511104*(127&r),!(128&r))return i?-(s+1)/2:s/2;if(t=BigInt(s),r=e[this._pos++],t+=0x2000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);if(r=e[this._pos++],t+=0x100000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);if(r=e[this._pos++],t+=0x8000000000000000n*BigInt(127&r),!(128&r))return Number(i?-(t+1n)/2n:t/2n);throw new Error("Varint too long!")}_getLength(){if(2!==this._dataType)throw new Error("Not a delimited data type!");return this._decodeVarint()}_getLengthUnsafe(){return this.getUInt32()}_toString(e,t,s){if((s=Math.min(this._end,s))-t>l){const r=e.subarray(t,s);return a.decode(r)}let r="",i="";for(let n=t;n<s;++n){const t=e[n];128&t?i+="%"+t.toString(16):(r+=decodeURIComponent(i)+String.fromCharCode(t),i="")}return i.length&&(r+=decodeURIComponent(i)),r}_toBytes(e,t,s){return s=Math.min(this._end,s),new Uint8Array(e.buffer,t,s-t)}static{this.pool=new n.A(u,void 0,e=>{e._data=null,e._dataView=null})}}},53177:(e,t,s)=>{s.d(t,{A:()=>c});var r,i=s(31635),n=s(4718),o=s(10107),a=(s(44208),s(53966),s(93223)),l=s(40608),u=s(39357),d=s(76357);let c=class extends d.A{static{r=this}constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const s=String(e);this.codedValues.some(e=>(String(e.code)===s&&(t=e.name),!!t))}return t}clone(){return new r({codedValues:(0,n.o8)(this.codedValues),name:this.name})}};(0,i.Cg)([(0,o.MZ)({type:[u.H],json:{write:{isRequired:!0}}})],c.prototype,"codedValues",void 0),(0,i.Cg)([(0,a.e)({codedValue:"coded-value"})],c.prototype,"type",void 0),c=r=(0,i.Cg)([(0,l.$)("esri.layers.support.CodedValueDomain")],c)},53655:(e,t,s)=>{s.d(t,{SH:()=>A,ae:()=>k,cn:()=>_});var r=s(49186),i=s(51624),n=s(92722),o=s(69418);const a=["esriFieldTypeSmallInteger","esriFieldTypeInteger","esriFieldTypeSingle","esriFieldTypeDouble","esriFieldTypeString","esriFieldTypeDate","esriFieldTypeOID","esriFieldTypeGeometry","esriFieldTypeBlob","esriFieldTypeRaster","esriFieldTypeGUID","esriFieldTypeGlobalID","esriFieldTypeXML","esriFieldTypeBigInteger","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"],l=["sqlTypeBigInt","sqlTypeBinary","sqlTypeBit","sqlTypeChar","sqlTypeDate","sqlTypeDecimal","sqlTypeDouble","sqlTypeFloat","sqlTypeGeometry","sqlTypeGUID","sqlTypeInteger","sqlTypeLongNVarchar","sqlTypeLongVarbinary","sqlTypeLongVarchar","sqlTypeNChar","sqlTypeNVarchar","sqlTypeOther","sqlTypeReal","sqlTypeSmallInt","sqlTypeSqlXml","sqlTypeTime","sqlTypeTimestamp","sqlTypeTimestamp2","sqlTypeTinyInt","sqlTypeVarbinary","sqlTypeVarchar"],u=["upperLeft","lowerLeft"];function d(e){return e>=a.length?null:a[e]}function c(e){return e>=l.length?null:l[e]}function p(e){return e>=u.length?null:u[e]}function h(e,t){return t>=e.geometryTypes.length?null:e.geometryTypes[t]}function g(e,t,s){const r=e.asUnsafe(),i=t.createPointGeometry(s);for(;r.next();)switch(r.tag()){case 3:{const e=r.getUInt32(),s=r.pos()+e;let n=0;for(;r.pos()<s;)t.addCoordinatePoint(i,r.getSInt64(),n++);break}default:r.skip()}return i}function y(e,t,s){const r=e.asUnsafe(),i=t.createGeometry(s),n=2+(s.hasZ?1:0)+(s.hasM?1:0);for(;r.next();)switch(r.tag()){case 2:{const e=r.getUInt32(),s=r.pos()+e;let n=0;for(;r.pos()<s;)t.addLength(i,r.getUInt32(),n++);break}case 3:{const e=r.getUInt32(),s=r.pos()+e;let o=0;for(t.allocateCoordinates(i);r.pos()<s;)t.addCoordinate(i,r.getSInt64(),o),o++,o===n&&(o=0);break}default:r.skip()}return i}function f(e){const t=e.asUnsafe(),s=new n.A;let r="esriGeometryPoint";for(;t.next();)switch(t.tag()){case 2:{const e=t.getUInt32(),r=t.pos()+e;for(;t.pos()<r;)s.lengths.push(t.getUInt32());break}case 3:{const e=t.getUInt32(),r=t.pos()+e;for(;t.pos()<r;)s.coords.push(t.getSInt64());break}case 1:r=o.z[t.getEnum()];break;default:t.skip()}return{queryGeometry:s,queryGeometryType:r}}function m(e){const t=e.asUnsafe();for(;t.next();)switch(t.tag()){case 1:return t.getString();case 2:return t.getFloat();case 3:return t.getDouble();case 4:return t.getSInt32();case 5:return t.getUInt32();case 6:return t.getInt64();case 7:return t.getUInt64();case 8:return t.getSInt64();case 9:return t.getBool();default:return t.skip(),null}return null}function _(e){const t=e.asUnsafe(),s={type:d(0)};for(;t.next();)switch(t.tag()){case 1:s.name=t.getString();break;case 2:s.type=d(t.getEnum());break;case 3:s.alias=t.getString();break;case 4:s.sqlType=c(t.getEnum());break;case 5:default:t.skip();break;case 6:s.defaultValue=t.getString()}return s}function b(e){const t={},s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:t.name=s.getString();break;case 2:t.isSystemMaintained=s.getBool();break;default:s.skip()}return t}function w(e,t,s,r){const i=t.createFeature(s);let n=0;for(;e.next();)switch(e.tag()){case 1:{const t=r[n++].name;i.attributes[t]=e.processMessage(m);break}case 2:i.geometry=e.processMessageWithArgs(y,t,s);break;case 4:i.centroid=e.processMessageWithArgs(g,t,s);break;default:e.skip()}return i}function v(e){const t=[1,1,1,1],s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:t[0]=s.getDouble();break;case 2:t[1]=s.getDouble();break;case 4:t[2]=s.getDouble();break;case 3:t[3]=s.getDouble();break;default:s.skip()}return t}function S(e){const t=[0,0,0,0],s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:t[0]=s.getDouble();break;case 2:t[1]=s.getDouble();break;case 4:t[2]=s.getDouble();break;case 3:t[3]=s.getDouble();break;default:s.skip()}return t}function k(e){const t={originPosition:p(0)},s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:t.originPosition=p(s.getEnum());break;case 2:t.scale=s.processMessage(v);break;case 3:t.translate=s.processMessage(S);break;default:s.skip()}return t}function x(e){const t={},s=e.asUnsafe();for(;s.next();)switch(s.tag()){case 1:t.shapeAreaFieldName=s.getString();break;case 2:t.shapeLengthFieldName=s.getString();break;case 3:t.units=s.getString();break;default:s.skip()}return t}function T(e,t){const s=t.createSpatialReference();for(;e.next();)switch(e.tag()){case 1:s.wkid=e.getUInt32();break;case 5:s.wkt=e.getString();break;case 2:s.latestWkid=e.getUInt32();break;case 3:s.vcsWkid=e.getUInt32();break;case 4:s.latestVcsWkid=e.getUInt32();break;default:e.skip()}return s}function I(e,t){const s=t.createFeatureResult(),r=e.asUnsafe();s.geometryType=h(t,0);let i=!1;for(;r.next();)switch(r.tag()){case 1:s.objectIdFieldName=r.getString();break;case 3:s.globalIdFieldName=r.getString();break;case 4:s.geohashFieldName=r.getString();break;case 5:s.geometryProperties=r.processMessage(x);break;case 7:s.geometryType=h(t,r.getEnum());break;case 8:s.spatialReference=r.processMessageWithArgs(T,t);break;case 10:s.hasZ=r.getBool();break;case 11:s.hasM=r.getBool();break;case 12:s.transform=r.processMessage(k);break;case 9:s.exceededTransferLimit=r.getBool();break;case 13:t.addField(s,r.processMessage(_));break;case 15:i||(t.prepareFeatures(s),i=!0),t.addFeature(s,r.processMessageWithArgs(w,t,s,s.fields));break;case 2:s.uniqueIdField=r.processMessage(b);break;default:r.skip()}return t.finishFeatureResult(s),s}function C(e,t){const s={};let r=null;for(;e.next();)switch(e.tag()){case 4:r=e.processMessageWithArgs(f);break;case 1:s.featureResult=e.processMessageWithArgs(I,t);break;default:e.skip()}return null!=r&&s.featureResult&&t.addQueryGeometry(s,r),s}function A(e,t){try{const s=2,r=new i.A(new Uint8Array(e),new DataView(e)),n={};for(;r.next();)r.tag()===s?n.queryResult=r.processMessageWithArgs(C,t):r.skip();return n}catch(e){throw new r.A("query:parsing-pbf","Error while parsing FeatureSet PBF payload",{error:e})}}},58501:(e,t,s)=>{s.d(t,{q:()=>i});var r=s(62815);function i(e,t,s){if(!s?.features||!s.hasZ)return;const i=(0,r.N)(s.geometryType,t,e.outSpatialReference);if(null!=i)for(const e of s.features)i(e.geometry)}},66208:(e,t,s)=>{s.d(t,{m:()=>i});var r=s(53655);function i(e,t){const s=(0,r.SH)(e,t),i=s.queryResult.featureResult,n=s.queryResult.queryGeometry,o=s.queryResult.queryGeometryType;if(i&&i.features&&i.features.length&&i.objectIdFieldName){const e=i.objectIdFieldName;for(const t of i.features)t.attributes&&(t.objectId=t.attributes[e])}return i&&(i.queryGeometry=n,i.queryGeometryType=o),i}},69418:(e,t,s)=>{s.d(t,{S:()=>u,z:()=>l});var r=s(83047),i=s(21325),n=s(43334),o=s(58512),a=s(92722);const l=["esriGeometryPoint","esriGeometryMultipoint","esriGeometryPolyline","esriGeometryPolygon"];class u{constructor(e){this._options=e,this.geometryTypes=l,this._coordinatePtr=0,this._vertexDimension=0}createFeatureResult(){return new o.A}prepareFeatures(e){this._vertexDimension=2,e.hasZ&&this._vertexDimension++,e.hasM&&this._vertexDimension++}finishFeatureResult(e){if(!e?.features||!e.hasZ||!this._options.sourceSpatialReference||!e.spatialReference||(0,i.aI)(e.spatialReference,this._options.sourceSpatialReference)||e.spatialReference.vcsWkid)return;const t=(0,r.G9)(this._options.sourceSpatialReference)/(0,r.G9)(e.spatialReference);if(1!==t)for(const s of e.features){if(!(0,n.N3)(s))continue;const e=s.geometry.coords;for(let s=2;s<e.length;s+=3)e[s]*=t}}addFeature(e,t){e.features.push(t)}createFeature(){return new n.Om(null,{},null,0)}createSpatialReference(){return{wkid:0}}createGeometry(){return new a.A}addField(e,t){e.fields.push(t)}allocateCoordinates(e){e.coords.length=e.lengths.reduce((e,t)=>e+t,0)*this._vertexDimension,this._coordinatePtr=0}addCoordinate(e,t){e.coords[this._coordinatePtr++]=t}addCoordinatePoint(e,t){e.coords.push(t)}addLength(e,t){e.lengths.push(t)}addQueryGeometry(e,t){e.queryGeometry=t.queryGeometry,e.queryGeometryType=t.queryGeometryType}createPointGeometry(){return new a.A}}},72802:(e,t,s)=>{s.d(t,{U:()=>r});class r{constructor(e,t,s,r,i=void 0){this.id=e,this.level=t,this.row=s,this.col=r,this.extent=i}}},76357:(e,t,s)=>{s.d(t,{A:()=>d});var r=s(31635),i=s(66552),n=s(25482),o=s(10107),a=(s(44208),s(53966),s(87811),s(93223)),l=s(40608);const u=new i.J({inherited:"inherited",codedValue:"coded-value",range:"range"});let d=class extends n.o{constructor(e){super(e),this.name=null,this.type=null}};(0,r.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],d.prototype,"name",void 0),(0,r.Cg)([(0,a.e)(u),(0,o.MZ)({json:{write:{isRequired:!0}}})],d.prototype,"type",void 0),d=(0,r.Cg)([(0,l.$)("esri.layers.support.Domain")],d)},79897:(e,t,s)=>{s.d(t,{U:()=>d});var r=s(31635),i=s(65008),n=s(36563),o=s(36708),a=s(96211),l=s(10107),u=s(40608);let d=class extends i.A{constructor(){super(...arguments),this.updating=!1,this._handleId=0,this._scheduleHandleId=0,this._pendingPromises=new Set}destroy(){this.removeAll()}add(e,t,s={}){return this._installWatch(e,t,s,o.wB)}addWhen(e,t,s={}){return this._installWatch(e,t,s,o.z7)}addOnCollectionChange(e,t,{initial:s=!1,final:r=!1}={}){const i=++this._handleId;return this.addHandles([(0,o.on)(e,"after-changes",this._createSyncUpdatingCallback(),o.OH),(0,o.on)(e,"change",t,{onListenerAdd:s?e=>t({added:e.toArray(),removed:[]}):void 0,onListenerRemove:r?e=>t({added:[],removed:e.toArray()}):void 0})],i),(0,n.hA)(()=>this.removeHandles(i))}addPromise(e){if(null==e)return e;const t=++this._handleId;this.addHandles((0,n.hA)(()=>{this._pendingPromises.delete(e)&&(0!==this._pendingPromises.size||this.hasHandles(c)||this._set("updating",!1))}),t),this._pendingPromises.add(e),this._set("updating",!0);const s=()=>this.removeHandles(t);return e.then(s,s),e}removeAll(){this._pendingPromises.clear(),this.removeAllHandles(),this._set("updating",!1)}_installWatch(e,t,s={},r){const i=++this._handleId;s.sync||this._installSyncUpdatingWatch(e,i);const o=r(e,t,s);return this.addHandles(o,i),(0,n.hA)(()=>this.removeHandles(i))}_installSyncUpdatingWatch(e,t){const s=this._createSyncUpdatingCallback(),r=(0,o.wB)(e,s,{sync:!0,equals:()=>!1});return this.addHandles(r,t),r}_createSyncUpdatingCallback(){return()=>{this.removeHandles(c),++this._scheduleHandleId;const e=this._scheduleHandleId;this._get("updating")||this._set("updating",!0),this.addHandles((0,a._)(()=>{e===this._scheduleHandleId&&(this._set("updating",this._pendingPromises.size>0),this.removeHandles(c))}),c)}}};(0,r.Cg)([(0,l.MZ)({readOnly:!0})],d.prototype,"updating",void 0),d=(0,r.Cg)([(0,u.$)("esri.core.support.UpdatingHandles")],d);const c=-42},80451:(e,t,s)=>{s.d(t,{rS:()=>g,gK:()=>h}),s(44208);var r,i=s(53177),n=s(76357),o=s(31635),a=(s(53966),s(87811),s(49186),s(93223)),l=s(40608);let u=class extends n.A{static{r=this}constructor(e){super(e),this.type="inherited"}clone(){return new r}};(0,o.Cg)([(0,a.e)({inherited:"inherited"})],u.prototype,"type",void 0),u=r=(0,o.Cg)([(0,l.$)("esri.layers.support.InheritedDomain")],u);var d,c=s(10107);let p=class extends n.A{static{d=this}constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new d({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,o.Cg)([(0,c.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,s){t[s]=[this.minValue||0,e]},isRequired:!0}}})],p.prototype,"maxValue",void 0),(0,o.Cg)([(0,c.MZ)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,s){t[s]=[e,this.maxValue||0]},isRequired:!0}}})],p.prototype,"minValue",void 0),(0,o.Cg)([(0,a.e)({range:"range"})],p.prototype,"type",void 0),p=d=(0,o.Cg)([(0,l.$)("esri.layers.support.RangeDomain")],p);const h={key:"type",base:n.A,typeMap:{range:p,"coded-value":i.A,inherited:u}};function g(e){if(!e?.type)return null;switch(e.type){case"range":return p.fromJSON(e);case"codedValue":return i.A.fromJSON(e);case"inherited":return u.fromJSON(e)}return null}},80893:(e,t,s)=>{s.d(t,{IJ:()=>g,Jf:()=>_,Pk:()=>f,eW:()=>h,gW:()=>m,kS:()=>y});var r=s(78888),i=s(84952),n=s(65864),o=s(17136),a=s(21325),l=s(10536),u=s(66208),d=s(58501);const c="Layer does not support extent calculation.";function p(e,t,s){const r=e.geometry,i=e.toJSON();delete i.compactGeometryEnabled,delete i.defaultSpatialReferenceEnabled;const o=i;let l,u,d;if(r&&(u=r.spatialReference,d=(0,a.YX)(u),o.geometryType=(0,n.$B)(r),o.geometry=function(e,t){if(t&&"extent"===e.type)return`${e.xmin},${e.ymin},${e.xmax},${e.ymax}`;if(t&&"point"===e.type)return`${e.x},${e.y}`;const s=e.toJSON();return delete s.spatialReference,JSON.stringify(s)}(r,e.compactGeometryEnabled),o.inSR=d),i.groupByFieldsForStatistics&&(o.groupByFieldsForStatistics=i.groupByFieldsForStatistics.join(",")),i.objectIds)switch(s?.uniqueIdFields?.length){case void 0:o.objectIds=i.objectIds.join(",");break;case 1:o.uniqueIds=JSON.stringify(i.objectIds),delete o.objectIds;break;default:o.uniqueIds=JSON.stringify(i.objectIds.map(e=>JSON.parse(e))),delete o.objectIds}if(i.orderByFields&&(o.orderByFields=i.orderByFields.join(",")),!i.outFields||!i.returnDistinctValues&&(t?.returnCountOnly||t?.returnExtentOnly||t?.returnIdsOnly)?delete o.outFields:i.outFields.includes("*")?o.outFields="*":o.outFields=i.outFields.join(","),i.outSR?(o.outSR=(0,a.YX)(i.outSR),l=e.outSpatialReference):r&&(i.returnGeometry||i.returnCentroid)&&(o.outSR=o.inSR,l=u),i.returnGeometry&&delete i.returnGeometry,i.outStatistics&&(o.outStatistics=JSON.stringify(i.outStatistics)),i.fullText&&(o.fullText=JSON.stringify(i.fullText)),i.pixelSize&&(o.pixelSize=JSON.stringify(i.pixelSize)),i.quantizationParameters&&(e.defaultSpatialReferenceEnabled&&null!=u&&null!=e.quantizationParameters?.extent&&u.equals(e.quantizationParameters.extent.spatialReference)&&delete i.quantizationParameters.extent.spatialReference,o.quantizationParameters=JSON.stringify(i.quantizationParameters)),i.parameterValues&&(o.parameterValues=JSON.stringify(i.parameterValues)),i.rangeValues&&(o.rangeValues=JSON.stringify(i.rangeValues)),i.dynamicDataSource&&(o.layer=JSON.stringify({source:i.dynamicDataSource}),delete i.dynamicDataSource),i.timeExtent){const e=i.timeExtent,{start:t,end:s}=e;null==t&&null==s||(o.time=t===s?t:`${t??"null"},${s??"null"}`),delete i.timeExtent}return e.defaultSpatialReferenceEnabled&&null!=u&&null!=l&&u.equals(l)&&(o.defaultSR=o.inSR,delete o.inSR,delete o.outSR),o}async function h(e,t,s,r,i){const n=t.timeExtent?.isEmpty?{data:{features:[]}}:await w(e,t,"json",r,void 0,i);return(0,d.q)(t,s,n.data),n}async function g(e,t,s,r,i){if(t.timeExtent?.isEmpty)return{data:s.createFeatureResult()};const n=await y(e,t,r,i),o=n;return o.data=(0,u.m)(n.data,s),o}function y(e,t,s,r){return w(e,t,"pbf",s,void 0,r)}function f(e,t,s,r){return t.timeExtent?.isEmpty?Promise.resolve({data:{objectIds:[]}}):w(e,t,"json",s,{returnIdsOnly:!0},r)}function m(e,t,s,r){return t.timeExtent?.isEmpty?Promise.resolve({data:{count:0}}):w(e,t,"json",s,{returnIdsOnly:!0,returnCountOnly:!0},r)}async function _(e,t,s){if(t.timeExtent?.isEmpty)return{data:{count:0,extent:null}};const r=await w(e,t,"json",s,{returnExtentOnly:!0,returnCountOnly:!0}),i=r.data;if(i.hasOwnProperty("extent"))return r;if(i.features)throw new Error(c);if(i.hasOwnProperty("count"))throw new Error(c);return r}function b(e,t){if(!e.returnIdsOnly||!t.uniqueIdFields)return e;const s={...e,returnUniqueIdsOnly:!0};return delete s.returnIdsOnly,s}async function w(e,t,s,n={},a={},u={}){const d="string"==typeof e?(0,i.An)(e):e,c=t.geometry?[t.geometry]:[],h=await(0,o.el)(c,null,{signal:n.signal}),g=h?.[0];null!=g&&((t=t.clone()).geometry=g);const y=(0,l.z)({...d.query,f:s,...b(a,u),...p(t,a,u)});return(0,r.A)((0,i.fj)(d.path,(f=a,null==t.formatOf3DObjects||f.returnCountOnly||f.returnExtentOnly||f.returnIdsOnly?"query":"query3d")),{...n,responseType:"pbf"===s?"array-buffer":"json",query:{...y,...n.query}});var f}},87045:(e,t,s)=>{s.d(t,{A:()=>v});var r,i=s(31635),n=s(66552),o=s(25482),a=s(83047),l=s(10107),u=s(56507),d=(s(44208),s(87811),s(36005)),c=s(40608),p=s(43937),h=s(86738),g=s(16930),y=s(19419),f=s(21325),m=s(28735),_=s(91806),b=s(72802);const w=new n.J({PNG:"png",PNG8:"png8",PNG24:"png24",PNG32:"png32",JPEG:"jpg",JPG:"jpg",DIB:"dib",TIFF:"tiff",EMF:"emf",PS:"ps",PDF:"pdf",GIF:"gif",SVG:"svg",SVGZ:"svgz",Mixed:"mixed",MIXED:"mixed",LERC:"lerc",LERC2D:"lerc2d",RAW:"raw",pbf:"pbf"});let v=class extends o.o{static{r=this}static create(e={}){const{resolutionFactor:t=1,scales:s,size:i=256,spatialReference:n=g.A.WebMercator,numLODs:o=24}=e;if(!(0,f.fn)(n)){const e=[];if(s)for(let t=0;t<s.length;t++){const r=s[t];e.push(new _.A({level:t,scale:r,resolution:r}))}else{let t=5e-4;for(let s=o-1;s>=0;s--)e.unshift(new _.A({level:s,scale:t,resolution:t})),t*=2}return new r({dpi:96,lods:e,origin:new h.A(0,0,n),size:[i,i],spatialReference:n})}const l=(0,f.Vp)(n),u=e.origin?new h.A({x:e.origin.x,y:e.origin.y,spatialReference:n}):new h.A(l?{x:l.origin[0],y:l.origin[1],spatialReference:n}:{x:0,y:0,spatialReference:n}),d=1/(39.37*(0,a.GA)(n)*96),c=[];if(s)for(let e=0;e<s.length;e++){const t=s[e],r=t*d;c.push(new _.A({level:e,scale:t,resolution:r}))}else{let e=(0,f.EA)(n)?512/i*591657527.5917094:256/i*591657527.591555;const s=Math.ceil(o/t);c.push(new _.A({level:0,scale:e,resolution:e*d}));for(let r=1;r<s;r++){const s=e/2**t,i=s*d;c.push(new _.A({level:r,scale:s,resolution:i})),e=s}}return new r({dpi:96,lods:c,origin:u,size:[i,i],spatialReference:n})}constructor(e){super(e),this.dpi=96,this.format=null,this.origin=null,this.size=null,this.spatialReference=null}get isWrappable(){const{spatialReference:e,origin:t}=this;if(e&&t){const s=(0,f.Vp)(e);return e.isWrappable&&!!s&&Math.abs(s.origin[0]-t.x)<=s.dx}return!1}readOrigin(e,t){return h.A.fromJSON({spatialReference:t.spatialReference,...e})}set lods(e){let t=0,s=0;const r=[],i=this._levelToLOD={};e&&(t=-1/0,s=1/0,e.forEach(e=>{r.push(e.scale),t=e.scale>t?e.scale:t,s=e.scale<s?e.scale:s,i[e.level]=e})),this._set("scales",r),this._set("lods",e),this._initializeUpsampleLevels()}readSize(e,t){return[t.cols,t.rows]}writeSize(e,t){t.cols=e[0],t.rows=e[1]}zoomToScale(e){const t=this.scales;if(e<=0)return t[0];if(e>=t.length-1)return t[t.length-1];const s=Math.floor(e),r=s+1;return t[s]/(t[s]/t[r])**(e-s)}scaleToZoom(e){const t=this.scales,s=t.length-1;let r=0;for(;r<s;r++){const s=t[r],i=t[r+1];if(s<=e)return r;if(i===e)return r+1;if(s>e&&i<e)return r+Math.log(s/e)/Math.log(s/i)}return r}tileAt(e,t,s,r){const i=this.lodAt(e);if(!i)return null;let n,o;if("number"==typeof t)n=t,o=s;else if((0,f.aI)(t.spatialReference,this.spatialReference))n=t.x,o=t.y,r=s;else{const e=(0,m.Cv)(t,this.spatialReference);if(null==e)return null;n=e.x,o=e.y,r=s}const a=i.resolution*this.size[0],l=i.resolution*this.size[1];return r||(r=new b.U(null,0,0,0,(0,y.vt)())),r.level=e,r.row=Math.floor((this.origin.y-o)/l+.001),r.col=Math.floor((n-this.origin.x)/a+.001),this.updateTileInfo(r),r}updateTileInfo(e,t=0){let s=this.lodAt(e.level);if(!s&&1===t){const t=this.lods[this.lods.length-1];t.level<e.level&&(s=t)}if(!s)return;const r=e.level-s.level,i=s.resolution*this.size[0]/2**r,n=s.resolution*this.size[1]/2**r;e.id=`${e.level}/${e.row}/${e.col}`,e.extent||(e.extent=(0,y.vt)()),e.extent[0]=this.origin.x+e.col*i,e.extent[1]=this.origin.y-(e.row+1)*n,e.extent[2]=e.extent[0]+i,e.extent[3]=e.extent[1]+n}upsampleTile(e){const t=this._upsampleLevels[e.level];return!(!t||-1===t.parentLevel||(e.level=t.parentLevel,e.row=Math.floor(e.row/t.factor+.001),e.col=Math.floor(e.col/t.factor+.001),this.updateTileInfo(e),0))}getTileBounds(e,t){const s=this.lodAt(t.level);if(null==s)return null;const{resolution:r}=s,i=r*this.size[0],n=r*this.size[1];return e[0]=this.origin.x+t.col*i,e[1]=this.origin.y-(t.row+1)*n,e[2]=e[0]+i,e[3]=e[1]+n,e}lodAt(e){return this._levelToLOD?.[e]??null}clone(){return r.fromJSON(this.write({}))}getCompatibleForVTL(e){if(this.size[0]!==this.size[1]||256===this.size[0]&&512===e)return null;const t=(512===this.size[0]&&256===e?-1:0)+(this.spatialReference.isGeographic?1:0);if(this.size[0]===e&&0===t)return this;const s=[],i=this.lods.length-t;for(let e=0;e<i;e++){const r=e+t,{scale:i,resolution:n}=r>=0?this.lods[r]:{scale:2*this.lods[0].scale,resolution:2*this.lods[0].resolution};s.push(new _.A({level:e,scale:i,resolution:n}))}return new r({size:[e,e],dpi:this.dpi,format:this.format,compressionQuality:this.compressionQuality,origin:this.origin,spatialReference:this.spatialReference,lods:s})}_initializeUpsampleLevels(){const e=this.lods;this._upsampleLevels=[];let t=null;for(let s=0;s<e.length;s++){const r=e[s];this._upsampleLevels[r.level]={parentLevel:t?t.level:-1,factor:t?t.resolution/r.resolution:0},t=r}}};(0,i.Cg)([(0,l.MZ)({type:Number,json:{write:!0}})],v.prototype,"compressionQuality",void 0),(0,i.Cg)([(0,l.MZ)({type:Number,json:{write:!0}})],v.prototype,"dpi",void 0),(0,i.Cg)([(0,l.MZ)({type:String,json:{read:w.read,write:w.write,origins:{"web-scene":{read:!1,write:!1}}}})],v.prototype,"format",void 0),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],v.prototype,"isWrappable",null),(0,i.Cg)([(0,l.MZ)({type:h.A,json:{write:!0}})],v.prototype,"origin",void 0),(0,i.Cg)([(0,d.w)("origin")],v.prototype,"readOrigin",null),(0,i.Cg)([(0,l.MZ)({type:[_.A],value:null,json:{write:!0}})],v.prototype,"lods",null),(0,i.Cg)([(0,l.MZ)({readOnly:!0})],v.prototype,"scales",void 0),(0,i.Cg)([(0,l.MZ)({cast:e=>Array.isArray(e)?e:"number"==typeof e?[e,e]:[256,256]})],v.prototype,"size",void 0),(0,i.Cg)([(0,d.w)("size",["rows","cols"])],v.prototype,"readSize",null),(0,i.Cg)([(0,p.K)("size",{cols:{type:u.jz},rows:{type:u.jz}})],v.prototype,"writeSize",null),(0,i.Cg)([(0,l.MZ)({type:g.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),v=r=(0,i.Cg)([(0,c.$)("esri.layers.support.TileInfo")],v)},91806:(e,t,s)=>{s.d(t,{A:()=>u});var r,i=s(31635),n=s(25482),o=s(10107),a=s(56507),l=(s(44208),s(87811),s(40608));let u=class extends n.o{static{r=this}constructor(e){super(e),this.cols=null,this.level=0,this.levelValue=null,this.origin=null,this.resolution=0,this.rows=null,this.scale=0}clone(){return new r({cols:this.cols,level:this.level,levelValue:this.levelValue,resolution:this.resolution,rows:this.rows,scale:this.scale})}};(0,i.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],u.prototype,"cols",void 0),(0,i.Cg)([(0,o.MZ)({type:a.jz,json:{write:!0}})],u.prototype,"level",void 0),(0,i.Cg)([(0,o.MZ)({type:String,json:{write:!0}})],u.prototype,"levelValue",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],u.prototype,"origin",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],u.prototype,"resolution",void 0),(0,i.Cg)([(0,o.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],u.prototype,"rows",void 0),(0,i.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],u.prototype,"scale",void 0),u=r=(0,i.Cg)([(0,l.$)("esri.layers.support.LOD")],u)}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1202],{60999:(e,t,n)=>{n.d(t,{DZ:()=>f,Ke:()=>y,Tj:()=>c,UT:()=>h,jJ:()=>l});var s=n(31635),r=n(65008),i=n(97768),o=n(74887),a=n(10107),u=n(40608);function l(e,t,n){return(0,o.Lx)(e.map((e,s)=>t.apply(n,[e,s])))}async function c(e,t,n){return(await(0,o.Lx)(e.map((e,s)=>t.apply(n,[e,s])))).map(e=>e.value)}function p(e){return{ok:!0,value:e}}function d(e){return{ok:!1,error:e}}async function y(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return d(e)}}async function f(e){try{return p(await e)}catch(e){return(0,o.QP)(e),d(e)}}function h(e,t){return new m(e,t)}let m=class extends r.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,i.DC)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then(e=>{this._result=p(e),this._cleanup()},e=>{this._result=d(e),this._cleanup()}),this._abortHandle=(0,o.u7)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,i.xt)(this._abortHandle),this._abortController=null}};(0,s.Cg)([(0,a.MZ)()],m.prototype,"value",null),(0,s.Cg)([(0,a.MZ)()],m.prototype,"error",null),(0,s.Cg)([(0,a.MZ)()],m.prototype,"finished",null),(0,s.Cg)([(0,a.MZ)()],m.prototype,"promise",void 0),(0,s.Cg)([(0,a.MZ)()],m.prototype,"_result",void 0),m=(0,s.Cg)([(0,u.$)("esri.core.asyncUtils.ReactiveTask")],m)},64714:(e,t,n)=>{n.d(t,{F0:()=>a,Vx:()=>c,e2:()=>d,f:()=>y});var s=n(44208),r=n(4718),i=n(99352),o=n(93470);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.Cb:"esriGeometryPolyline"===e?o.yM:o.WR}}}const u=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let l=1;function c(e,t){if((0,s.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let n=`this${p(t)} = null;`;for(const t in e)n+=`this${p(t)} = ${JSON.stringify(e[t])};`;const s=new Function(`\n return class AttributesClass$${l++} {\n constructor() {\n ${n};\n }\n }\n `)();return()=>new s}catch(n){return()=>({[t]:null,...e})}}function p(e){return u.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,r.o8)(e)}}]}function y(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!1,isBranchVersioned:!1,supportsAttachment:!1,supportsM:!1,supportsZ:e},metadata:{supportsAdvancedFieldProperties:!1},operations:{supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsAdd:t,supportsDelete:t,supportsEditing:t,supportsChangeTracking:!1,supportsQuery:!0,supportsQueryBins:!0,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:i.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:i.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},67482:(e,t,n)=>{function s(e){return null!=a(e)||null!=o(e)}function r(e){return u.test(e)}function i(e){return a(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,s=0;for(;!t&&s<=e.length;)t=!l.test(e[s]),s++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function a(e){const t=u.exec(e);if(!t?.groups)return null;const n=t.groups,s=+n.year,r=+n.month-1,i=+n.day,o=+(n.hours??"0"),a=+(n.minutes??"0"),l=+(n.seconds??"0");if(o>23)return null;if(a>59)return null;if(l>59)return null;const c=n.ms??"0",p=c?+c.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(s,r,i,o,a,l,p);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(s,r,i,o,a,l,p)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>r,Cq:()=>s,_U:()=>i});const u=/^(?:(?<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})))?$/,l=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},71202:(e,t,n)=>{n.r(t),n.d(t,{default:()=>I});var s=n(78888),r=n(60999),i=n(49186),o=n(53966),a=n(74887),u=n(65864),l=n(21325),c=n(90708),p=n(58376),d=n(83221),y=n(31464),f=n(95422),h=n(85113),m=n(64714),g=n(82832),b=n(95466),_=n(98453),S=n(30524),w=n(98623);const F={hasAttachments:!1,capabilities:"query, editing, create, delete, update",useStandardizedQueries:!0,supportsCoordinatesQuantization:!0,supportsReturningQueryGeometry:!0,advancedQueryCapabilities:{supportsQueryAttachments:!1,supportsQueryAttachmentOrderByFields:!1,supportsQueryBins:!0,supportsQueryWithCacheHint:!0,supportsQueryWithDistance:!0,supportsQueryWithResultType:!0,supportsStatistics:!0,supportsPercentileStatistics:!0,supportsReturningGeometryCentroid:!0,supportsDistinct:!0,supportsReturningQueryExtent:!0,supportsReturningGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsSqlExpression:!0,supportsDisjointSpatialRel:!0},queryBinsCapabilities:g.PC};class I{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=this._createDefaultAttributes=null}async load(e,t={}){this._loadOptions={url:e.url,customParameters:e.customParameters};const n=[],[s]=await Promise.all([e.url?this._fetch(t?.signal):null,this._checkProjection(e.spatialReference)]),r=(0,h.BM)(s,{geometryType:e.geometryType}),o=e.fields||r.fields||[],a=null!=e.hasZ?e.hasZ:r.hasZ,u=r.geometryType;let c=e.objectIdField||r.objectIdFieldName||"__OBJECTID";const p=e.spatialReference||l.KK;let y=e.timeInfo;o===r.fields&&r.unknownFields.length>0&&n.push({name:"geojson-layer:unknown-field-types",message:"Some fields types couldn't be inferred from the features and were dropped",details:{unknownFields:r.unknownFields}});const g=new b.A(o);let I=g.get(c);I?("esriFieldTypeString"!==I.type&&(I.type="esriFieldTypeOID"),I.editable=!1,I.nullable=!1,c=I.name):(I={alias:c,name:c,type:"string"===r.objectIdFieldType?"esriFieldTypeString":"esriFieldTypeOID",editable:!1,nullable:!1},o.unshift(I));const T={};for(const e of o){if(null==e.name&&(e.name=e.alias),null==e.alias&&(e.alias=e.name),!e.name)throw new i.A("geojson-layer:invalid-field-name","field name is missing",{field:e});if(!_.m.jsonValues.includes(e.type))throw new i.A("geojson-layer:invalid-field-type",`invalid type for field "${e.name}"`,{field:e});if(e.name!==I.name){const t=(0,S.lD)(e);void 0!==t&&(T[e.name]=t)}null==e.length&&(e.length=(0,S._b)(e))}if(y){if(y.startTimeField){const e=g.get(y.startTimeField);e?(y.startTimeField=e.name,e.type="esriFieldTypeDate"):y.startTimeField=null}if(y.endTimeField){const e=g.get(y.endTimeField);e?(y.endTimeField=e.name,e.type="esriFieldTypeDate"):y.endTimeField=null}if(y.trackIdField){const e=g.get(y.trackIdField);e?y.trackIdField=e.name:(y.trackIdField=null,n.push({name:"geojson-layer:invalid-timeInfo-trackIdField",message:"trackIdField is missing",details:{timeInfo:y}}))}y.startTimeField||y.endTimeField||(n.push({name:"geojson-layer:invalid-timeInfo",message:"startTimeField and endTimeField are missing",details:{timeInfo:y}}),y=null)}const E=u?(0,m.F0)(u):void 0,C=g.dateFields.length?{timeZoneIANA:w.n$}:null,j={warnings:n,featureErrors:[],layerDefinition:{...F,drawingInfo:E??void 0,templates:(0,m.e2)(T),extent:void 0,geometryType:u,objectIdField:c,fields:o,hasZ:!!a,timeInfo:y,dateFieldsTimeReference:C}},A={type:"object-id",fieldName:c};this._queryEngine=new f.do({fieldsIndex:b.A.fromLayerJSON({fields:o,timeInfo:y,dateFieldsTimeReference:C}),geometryType:u,hasM:!1,hasZ:a,featureIdInfo:A,spatialReference:p,timeInfo:y,featureStore:new d.A({geometryType:u,hasM:!1,hasZ:a})});const x=this._queryEngine.fieldsIndex.requiredFields.indexOf(I);x>-1&&this._queryEngine.fieldsIndex.requiredFields.splice(x,1),this._createDefaultAttributes=(0,m.Vx)(T,c);const q=this._createFeatures(s);this._objectIdGenerator=this._createObjectIdGenerator(this._queryEngine,q);const R=this._normalizeFeatures(q,j.featureErrors);this._queryEngine.featureStore.addMany(R);const{fullExtent:P,timeExtent:M}=await this._queryEngine.fetchRecomputedExtents();if(j.layerDefinition.extent=P,M){const{start:e,end:t}=M;j.layerDefinition.timeInfo.timeExtent=[e,t]}return j}async applyEdits(e){const{spatialReference:t,geometryType:n}=this._queryEngine;return await Promise.all([(0,g.$1)(t,n),(0,y.Nk)(e.adds,t),(0,y.Nk)(e.updates,t)]),await this._waitSnapshotComplete(),this._applyEdits(e)}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForIds(e,t.signal)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),(0,p.J)(this._queryEngine,e,t.signal)}async queryAttributeBins(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeAttributeBinsQuery(e,t.signal)}async refresh(e){this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.UT)(this._snapshotFeatures),this._snapshotTask.promise.then(e=>{this._queryEngine.featureStore.clear(),this._objectIdGenerator=this._createObjectIdGenerator(this._queryEngine,e);const t=this._normalizeFeatures(e);t&&this._queryEngine.featureStore.addMany(t)},e=>{this._queryEngine.featureStore.clear(),(0,a.zf)(e)||o.A.getLogger("esri.layers.GeoJSONLayer").error(new i.A("geojson-layer:refresh","An error occurred during refresh",{error:e}))}),await this._waitSnapshotComplete();const{fullExtent:t,timeExtent:n}=await this._queryEngine.fetchRecomputedExtents();return{extent:t,timeExtent:n}}_createFeatures(e){if(null==e)return[];const{geometryType:t,hasZ:n,objectIdField:s}=this._queryEngine,r=(0,h.bd)(e,{geometryType:t,hasZ:n,objectIdField:s});if(!(0,l.aI)(this._queryEngine.spatialReference,l.KK))for(const e of r)null!=e.geometry&&(e.geometry=(0,c.Ux)((0,y.Cv)((0,c.zv)(e.geometry,this._queryEngine.geometryType,this._queryEngine.hasZ,!1),l.KK,this._queryEngine.spatialReference)));return r}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:n}=this._loadOptions,r=(await(0,s.A)(t??"",{responseType:"json",query:{...n},signal:e})).data;return(0,h.sO)(r),r}_normalizeFeatures(e,t){const{objectIdField:n,fieldsIndex:s}=this._queryEngine,r=[];for(const i of e){const e=this._createDefaultAttributes(),o=(0,g.MB)(s,e,i.attributes,!0);o?t?.push(o):(this._assignObjectId(e,i.attributes,!0),i.attributes=e,i.objectId=e[n],r.push(i))}return r}async _applyEdits(e){const{adds:t,updates:n,deletes:s}=e,r={addResults:[],deleteResults:[],updateResults:[],uidToObjectId:{}};if(t?.length&&this._applyAddEdits(r,t),n?.length&&this._applyUpdateEdits(r,n),s?.length){for(const e of s)r.deleteResults.push((0,g.bP)(e));this._queryEngine.featureStore.removeManyById(s)}const{fullExtent:i,timeExtent:o}=await this._queryEngine.fetchRecomputedExtents();return{extent:i,timeExtent:o,featureEditResults:r}}_applyAddEdits(e,t){const{addResults:n}=e,{geometryType:s,hasM:r,hasZ:i,objectIdField:o,spatialReference:a,featureStore:l,fieldsIndex:p}=this._queryEngine,d=[],f={type:"object-id",fieldName:o};for(const r of t){if(r.geometry&&s!==(0,u.$B)(r.geometry)){n.push((0,g.Yx)("Incorrect geometry type."));continue}const t=this._createDefaultAttributes(),i=(0,g.MB)(p,t,r.attributes);if(i)n.push(i);else{if(this._assignObjectId(t,r.attributes),r.attributes=t,null!=r.uid){const t=r.attributes[o];e.uidToObjectId[r.uid]=t}if(null!=r.geometry){const e=r.geometry.spatialReference??a;r.geometry=(0,y.Cv)((0,g.CR)(r.geometry,e),e,a)}d.push(r),n.push((0,g.bP)(r.attributes[o]))}}l.addMany((0,c.Di)([],d,s,i,r,f))}_applyUpdateEdits({updateResults:e},t){const{geometryType:n,hasM:s,hasZ:r,objectIdField:i,spatialReference:o,featureStore:a,fieldsIndex:l}=this._queryEngine,p={type:"object-id",fieldName:i};for(const d of t){const{attributes:t,geometry:f}=d,h=t?.[i];if(null==h){e.push((0,g.Yx)(`Identifier field ${i} missing`));continue}if(!a.has(h)){e.push((0,g.Yx)(`Feature with object id ${h} missing`));continue}const m=(0,c.oN)(a.getFeature(h),n,r,s);if(null!=f){if(n!==(0,u.$B)(f)){e.push((0,g.Yx)("Incorrect geometry type."));continue}const t=f.spatialReference??o;m.geometry=(0,y.Cv)((0,g.CR)(f,t),t,o)}if(t){const n=(0,g.MB)(l,m.attributes,t);if(n){e.push(n);continue}}a.add((0,c.E2)(m,n,r,s,p)),e.push((0,g.bP)(h))}}_createObjectIdGenerator(e,t){const n=e.fieldsIndex.get(e.objectIdField);if("esriFieldTypeString"===n.type)return()=>n.name+"-"+Date.now().toString(16);let s=Number.NEGATIVE_INFINITY;for(const e of t)e.objectId&&(s=Math.max(s,e.objectId));return s=Math.max(0,s)+1,()=>s++}_assignObjectId(e,t,n=!1){const s=this._queryEngine.objectIdField;e[s]=n&&s in t?t[s]:this._objectIdGenerator()}async _checkProjection(e){try{await(0,y.Nk)(l.KK,e)}catch{throw new i.A("geojson-layer","Projection not supported")}}}},82832:(e,t,n)=>{n.d(t,{$1:()=>m,CR:()=>h,MB:()=>d,PC:()=>g,Yx:()=>u,bP:()=>c});var s=n(67482),r=n(21325),i=n(30524);class o{constructor(e){this.description=e,this.code=null}}class a{constructor(e){this.globalId=null,this.objectId=null,this.success=!1,this.uniqueId=null,this.error=new o(e)}}function u(e){return new a(e)}class l{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function c(e){return new l(e)}const p=new Set;function d(e,t,n,s=!1){p.clear();for(const r in n){const o=e.get(r);if(!o)continue;const a=y(o,n[r]);if(p.add(o.name),o&&(s||o.editable)){const e=(0,i.CJ)(o,a);if(e)return u((0,i.uo)(e,o,a));t[o.name]=a}}for(const t of e.requiredFields??[])if(!p.has(t.name))return u(`missing required field "${t.name}"`);return null}function y(e,t){let n=t;return(0,i.WA)(e)&&"string"==typeof t?n=parseFloat(t):(0,i.yM)(e)&&null!=t&&"string"!=typeof t?n=String(t):(0,i.vE)(e)&&"string"==typeof t&&(n=(0,s._U)(t)),(0,i.WX)(n)}let f;function h(e,t){if(!e||!(0,r.fn)(t))return e;if("rings"in e||"paths"in e){if(null==f)throw new TypeError("geometry engine not loaded");return f.simplify(t,e)}return e}async function m(e,t){!(0,r.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==f&&(f=await Promise.all([n.e(9930),n.e(7559)]).then(n.bind(n,47559))),f}()}const g={supportsAutoIntervalBin:!0,supportsFixedIntervalBin:!0,supportsFixedBoundariesBin:!0,supportsDateBin:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsNormalization:!0,supportedStatisticTypes:["COUNT","SUM","AVG","VAR","STDDEV","MIN","MAX","PERCENTILE_CONT","PERCENTILE_DISC","CentroidAggregate","EnvelopeAggregate","ConvexHullAggregate"],supportedNormalizationTypes:["field","log","naturalLog","percentOfTotal","squareRoot"]}},85113:(e,t,n)=>{n.d(t,{BM:()=>T,bd:()=>E,sO:()=>I,xD:()=>c});var s=n(67482),r=n(49186),i=n(21325),o=n(43334),a=n(92722),u=n(30524);const l={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function c(e){return l[e]}function*p(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*d(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(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function y(e){for(const t of e)if(t.length>2)return!0;return!1}function f(e){let t=0;for(let n=0;n<e.length;n++){const s=e[n],r=e[(n+1)%e.length];t+=s[0]*r[1]-r[0]*s[1]}return t<=0}function h(e){const t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t),e}function m(e,t,n){switch(t.type){case"LineString":case"MultiPoint":return function(e,t,n){return _(e,t.coordinates,n),e}(e,t,n);case"MultiLineString":return function(e,t,n){for(const s of t.coordinates)_(e,s,n);return e}(e,t,n);case"MultiPolygon":return function(e,t,n){for(const s of t.coordinates){g(e,s[0],n);for(let t=1;t<s.length;t++)b(e,s[t],n)}return e}(e,t,n);case"Point":return function(e,t,n){return w(e,t.coordinates,n),e}(e,t,n);case"Polygon":return function(e,t,n){const s=t.coordinates;g(e,s[0],n);for(let t=1;t<s.length;t++)b(e,s[t],n);return e}(e,t,n)}}function g(e,t,n){const s=h(t);!function(e){return!f(e)}(s)?_(e,s,n):S(e,s,n)}function b(e,t,n){const s=h(t);!function(e){return f(e)}(s)?_(e,s,n):S(e,s,n)}function _(e,t,n){for(const s of t)w(e,s,n);e.lengths.push(t.length)}function S(e,t,n){for(let s=t.length-1;s>=0;s--)w(e,t[s],n);e.lengths.push(t.length)}function w(e,t,n){const[s,r,i]=t;e.coords.push(s,r),n.hasZ&&e.coords.push(i||0)}function F(e){switch(typeof e){case"string":return(0,s.Br)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function I(e,t=4326){if(!e)throw new r.A("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new r.A("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:n}=e;if(!n)return;const s="string"==typeof n?n:"name"===n.type?n.properties.name:"EPSG"===n.type?n.properties.code:null,o=(0,i.oT)({wkid:t})?new RegExp(".*(CRS84H?|4326)$","i"):new RegExp(`.*(${t})$`,"i");if(!s||!o.test(s))throw new r.A("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:n})}function T(e,t={}){const n=[],s=new Set,r=new Set;let i,o=!1,a=null,l=!1,{geometryType:f=null}=t;for(const t of p(e)){const{geometry:e,properties:p,id:h}=t;if((!e||(f||(f=c(e.type)),c(e.type)===f))&&(o||(o=y(d(e))),l||(l=null!=h,l&&(i=typeof h,p&&(a=Object.keys(p).filter(e=>p[e]===h)))),p&&a&&l&&null!=h&&(a.length>1?a=a.filter(e=>p[e]===h):1===a.length&&(a=p[a[0]]===h?a:[])),p))for(const e in p){if(s.has(e))continue;const t=F(p[e]);if("unknown"===t){r.add(e);continue}r.delete(e),s.add(e);const i=(0,u.rS)(e);i&&n.push({name:i,alias:e,type:t})}}const h=(0,u.rS)(1===a?.length&&a[0]||null)??void 0;if(h)for(const e of n)if(e.name===h&&(0,u.WA)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:f,hasZ:o,objectIdFieldName:h,objectIdFieldType:i,unknownFields:Array.from(r)}}function E(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:s}=t;for(const r of e){const{geometry:e,properties:i,id:u}=r;if(e&&c(e.type)!==n)continue;const l=i||{};let p;s&&(p=l[s],null==u||p||(l[s]=p=u));const d=new o.Om(e?m(new a.A,e,t):null,l,null,p);yield d}}(p(e),t))}},93470:(e,t,n)=>{n.d(t,{Cb:()=>i,HW:()=>c,JR:()=>r,JZ:()=>u,WR:()=>a,b6:()=>p,fT:()=>s,nC:()=>l,yM:()=>o});const s=[252,146,31,255],r=[153,153,153,255],i={type:"esriSMS",style:"esriSMSCircle",size:6,color:s,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:s},a={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},u={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},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},c={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},p={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);