@arcgis/core 5.0.0-next.18 → 5.0.0-next.19

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 (105) hide show
  1. package/AttributeBinsGraphic.js +1 -1
  2. package/analysis/ElevationProfile/ElevationProfileLineGround.js +1 -1
  3. package/analysis/ElevationProfile/ElevationProfileLineInput.js +1 -1
  4. package/analysis/ElevationProfile/ElevationProfileLineQuery.js +1 -1
  5. package/analysis/ElevationProfile/ElevationProfileLineScene.js +1 -1
  6. package/arcade/featureSetUtils.js +1 -1
  7. package/arcade/featureset/sources/FeatureLayerDynamic.js +1 -1
  8. package/arcade/featureset/sources/FeatureLayerMemory.js +1 -1
  9. package/arcade/featureset/sources/FeatureLayerOGC.js +5 -0
  10. package/arcade/featureset/sources/FeatureLayerRelated.js +1 -1
  11. package/arcade/featureset/support/FeatureSet.js +1 -1
  12. package/arcade/featureset/support/shared.js +1 -1
  13. package/assets/esri/core/workers/RemoteClient.js +1 -1
  14. package/assets/esri/core/workers/chunks/057d59ee6144e5890780.js +1 -0
  15. package/assets/esri/core/workers/chunks/{31b5900119dd7cd9e7d3.js → 0a6ad58ca4ca0cba2fa0.js} +1 -1
  16. package/assets/esri/core/workers/chunks/0d8d3d0de49064971874.js +1 -0
  17. package/assets/esri/core/workers/chunks/{b87bc987983b31c13f64.js → 0f1b9d69961dad0b922f.js} +1 -1
  18. package/assets/esri/core/workers/chunks/110cc01dd6af7ee125d4.js +1 -0
  19. package/assets/esri/core/workers/chunks/11687718c8635eb7bf37.js +1 -0
  20. package/assets/esri/core/workers/chunks/{5f6df4a3376b52ead53f.js → 14f994b1dd682bf2d61a.js} +1 -1
  21. package/assets/esri/core/workers/chunks/3538eb39ebb58acedd67.js +1 -0
  22. package/assets/esri/core/workers/chunks/{02a22dd6d208a925cc5a.js → 52cf643621662712dc85.js} +1 -1
  23. package/assets/esri/core/workers/chunks/5755b11272b777507612.js +1 -0
  24. package/assets/esri/core/workers/chunks/{d69265ceabfa92b40bb7.js → 58969dde8c3d0b2a9829.js} +1 -1
  25. package/assets/esri/core/workers/chunks/6e4829b52ade3e41ccc4.js +1 -0
  26. package/assets/esri/core/workers/chunks/{4a89e120be142ab58a27.js → 7224b321606116fd691c.js} +1 -1
  27. package/assets/esri/core/workers/chunks/{257f17b3836a623a9dbe.js → 795b09ff7a8f4e91f4dc.js} +1 -1
  28. package/assets/esri/core/workers/chunks/{3ac7562ea90f91a9f30c.js → 82b2741e75c2e9b88252.js} +1 -1
  29. package/assets/esri/core/workers/chunks/{5d2e5774768d8f290343.js → b656e8fd374113523404.js} +1 -1
  30. package/assets/esri/core/workers/chunks/bccb9ac572bc093fb177.js +1 -0
  31. package/assets/esri/core/workers/chunks/{79dbfa2b9b332ca0002f.js → c52161b94c0fb071747e.js} +1 -1
  32. package/assets/esri/core/workers/chunks/db76958fd9f54b6bd324.js +1 -0
  33. package/assets/esri/core/workers/chunks/e61d7762b56e36dc7e8a.js +1 -0
  34. package/assets/esri/core/workers/chunks/{b30897952494a3e5b9fe.js → e69c2b613bd0210e25ba.js} +1 -1
  35. package/assets/esri/core/workers/chunks/f43e1e1a1b2eb737e00c.js +1 -0
  36. package/assets/esri/libs/lyr3d/lyr3DMain.wasm +0 -0
  37. package/chunks/GlowComposition.glsl.js +46 -46
  38. package/chunks/ShadedColorMaterial.glsl.js +10 -10
  39. package/config.js +1 -1
  40. package/editing/templateUtils.js +1 -1
  41. package/interfaces.d.ts +120 -23
  42. package/kernel.js +1 -1
  43. package/layers/BingMapsLayer.js +1 -1
  44. package/layers/PointCloudLayer.js +1 -1
  45. package/layers/SceneLayer.js +1 -1
  46. package/layers/VideoLayer.js +1 -1
  47. package/layers/graphics/sources/OGCFeatureSource.js +1 -1
  48. package/layers/mixins/SceneService.js +1 -1
  49. package/layers/ogc/ogcFeatureUtils.js +1 -1
  50. package/libs/parquet/parquet.js +1 -1
  51. package/package.json +1 -1
  52. package/renderers/support/RasterSymbolizer.js +1 -1
  53. package/rest/support/QueryMixin.js +1 -1
  54. package/support/revision.js +1 -1
  55. package/symbols/cim/CIMSymbolDrawHelper.js +1 -1
  56. package/symbols/cim/cimAnalyzer.js +1 -1
  57. package/undoredo/support/ServiceVersionInfo.js +1 -1
  58. package/undoredo/support/Services.js +1 -1
  59. package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterHighlightTechnique.js +1 -1
  60. package/views/2d/engine/webgl/shaderGraph/techniques/raster/processor/textureUtils.js +1 -1
  61. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/BaseRasterHighlightShader.js +5 -0
  62. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterRangeHighlightShader.js +1 -1
  63. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/RasterXYBandHighlightShader.js +5 -0
  64. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/processor/math.js +1 -1
  65. package/views/2d/engine/webgl/shaderGraph/techniques/shaders/raster/stretch.js +1 -1
  66. package/views/2d/layers/ImageryTileLayerView2D.js +1 -1
  67. package/views/2d/layers/imagery/ImageryTileView2D.js +1 -1
  68. package/views/3d/environment/SceneViewEnvironment.js +1 -1
  69. package/views/3d/environment/SunLighting.js +1 -1
  70. package/views/3d/environment/VirtualLighting.js +1 -1
  71. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  72. package/views/3d/webgl-engine/effects/glow/GlowRenderNode.js +1 -1
  73. package/views/3d/webgl-engine/materials/CheckerBoardMaterial.js +1 -1
  74. package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
  75. package/views/3d/webgl-engine/materials/ShadedColorMaterial.js +1 -1
  76. package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
  77. package/widgets/Editor/SplitFeatureWorkflow.js +1 -1
  78. package/widgets/Editor/UpdateFeatureWorkflow.js +1 -1
  79. package/widgets/Editor/VisibleElements.js +1 -1
  80. package/widgets/Editor/components/UpdateFeaturePanelContent.js +1 -1
  81. package/widgets/Editor/workflowUtils.js +1 -1
  82. package/widgets/Editor.js +1 -1
  83. package/widgets/FeatureTable/FieldColumn.js +1 -1
  84. package/widgets/FeatureTable/Grid/Column.js +1 -1
  85. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  86. package/widgets/OrientedImageryViewer/adapters/sketch/MeasurementAdapter.js +1 -1
  87. package/widgets/OrientedImageryViewer/adapters/sketch/TriangulatedMeasurementAdapter.js +1 -1
  88. package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
  89. package/widgets/OrientedImageryViewer/services/ImageMeasurementService.js +1 -1
  90. package/widgets/OrientedImageryViewer.js +1 -1
  91. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
  92. package/widgets/smartMapping/SizeSlider.js +1 -1
  93. package/widgets/support/SelectionList/VisibleElements.js +1 -1
  94. package/widgets/support/SelectionList.js +1 -1
  95. package/assets/esri/core/workers/chunks/080268f78436a2f0d996.js +0 -1
  96. package/assets/esri/core/workers/chunks/18474c017ddacd1d3d2c.js +0 -1
  97. package/assets/esri/core/workers/chunks/27e6a6c5610007ac6a54.js +0 -1
  98. package/assets/esri/core/workers/chunks/5415fbcc7ed203fc5575.js +0 -1
  99. package/assets/esri/core/workers/chunks/631fb2e62e48f8be4051.js +0 -1
  100. package/assets/esri/core/workers/chunks/722da7a39a0ad9300752.js +0 -1
  101. package/assets/esri/core/workers/chunks/9595aabbaf411eceea1e.js +0 -1
  102. package/assets/esri/core/workers/chunks/a470f662d73aa8d5d90f.js +0 -1
  103. package/assets/esri/core/workers/chunks/a57751f3d78524c876cd.js +0 -1
  104. package/assets/esri/core/workers/chunks/ac366221e8636b60aee5.js +0 -1
  105. package/assets/esri/core/workers/chunks/dec336700cfb83abbbeb.js +0 -1
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[1221],{11221:(e,t,r)=>{r.d(t,{t1:()=>T,Jn:()=>b,An:()=>g});var a=r(48938),s=r(23732),n=r(87449),i=r(31635),l=r(93833),o=r(60999);class u{constructor(e,t){this._parent=e,this._abortSignal=t,this._done=!1,this._features=null,this._batchMutex=new o.aD,this._currentPage=null,this._pageCursor=-1}get _numAvailable(){return null==this._currentPage||this._pageCursor<0?0:Math.max(this._currentPage.length-this._pageCursor,0)}_takeNFeatures(e){if(null==this._currentPage)return[];const t=this._currentPage.slice(this._pageCursor,this._pageCursor+e);return this._pageCursor+=t.length,t}_takeOneFeature(){const e=this._currentPage[this._pageCursor];return this._pageCursor+=1,e}async _nextBatch(){if(this._done)return!1;const e=await(this._features??=this._parent.queryAll(this._abortSignal));let t;do{if(t=await e.next(),t.done)return this._done=!0,this._currentPage=null,this._pageCursor=-1,!1}while(t.value.length<=0);return this._currentPage=t.value,this._pageCursor=0,!0}async nextBatchAsArcadeFeatures(e,t){const r=await this.nextBatch(e);return null==r?r:r.map(e=>l.Xj.createFromGraphicLikeObject(e.geometry,e.attributes,this._parent,t))}async nextBatch(e){const t={stack:[],error:void 0,hasError:!1};try{if(this._done)return null;if(e<=0)return[];if((0,i.mS)(t,await this._batchMutex.acquire(),!1),this._numAvailable>=e)return this._takeNFeatures(e);const r=[];let a=e;do{const e=this._takeNFeatures(a);a-=e.length,r.push(e)}while(a>0&&await this._nextBatch());const s=r.flat();return s.length>0?s:null}catch(e){t.error=e,t.hasError=!0}finally{(0,i.hk)(t)}}async next(){const e={stack:[],error:void 0,hasError:!1};try{return this._done?null:((0,i.mS)(e,await this._batchMutex.acquire(),!1),this._numAvailable>=1||await this._nextBatch()?this._takeOneFeature():null)}catch(t){e.error=t,e.hasError=!0}finally{(0,i.hk)(e)}}}var c=r(33325),h=r(50145),d=r(71163),p=r(5479),f=r(88368),y=r(16930),m=r(95466);const g=Object.freeze({ordered:!0,filterApplied:!0,spatialFilterApplied:!0,features:Object.freeze({next:()=>Promise.resolve({done:!0,value:void 0}),[Symbol.asyncIterator](){return this}})});class T{constructor(){this.declaredRootClass="esri.arcade.featureset.support.FeatureSet",this._parent=null,this._maxProcessing=200,this._maxQuery=500,this._totalCount=-1,this._databaseType=7,this._databaseTypeProbed=null,this._loadPromise=null,this._allFeatures=null,this._fieldsIndex=null,this.typeIdField=null,this.types=null,this.subtypeField=null,this.subtypes=null,this.fields=null,this.geometryType="",this.objectIdField="",this.globalIdField="",this.spatialReference=null,this.hasM=!1,this.hasZ=!1}_ensureLoaded(){return this.load()}load(){return null===this._loadPromise&&(this._loadPromise=this.loadImpl()),this._loadPromise}async loadImpl(){return await(this._parent?.load()),this._initialiseFeatureSet(),this}_initialiseFeatureSet(){null!==this._parent?(this.fields=this._parent.fields.slice(),this.geometryType=this._parent.geometryType,this.objectIdField=this._parent.objectIdField,this.globalIdField=this._parent.globalIdField,this.spatialReference=this._parent.spatialReference,this.hasM=this._parent.hasM,this.hasZ=this._parent.hasZ,this.typeIdField=this._parent.typeIdField,this.types=this._parent.types,this.subtypeField=this._parent.subtypeField,this.subtypes=this._parent.subtypes):(this.fields=[],this.typeIdField="",this.subtypeField="",this.objectIdField="",this.globalIdField="",this.spatialReference=new y.A({wkid:4326}),this.geometryType=c.ik.point)}getField(e,t){return e=e.toLowerCase(),(t||this.fields).find(t=>t.name.toLowerCase()===e)}getFieldsIndex(){return null===this._fieldsIndex&&(this._fieldsIndex=m.A.fromLayer({timeInfo:this.timeInfo,editFieldsInfo:this.editFieldsInfo,dateFieldsTimeZone:this.dateFieldsTimeZone,datesInUnknownTimezone:this.datesInUnknownTimezone,fields:this.fields})),this._fieldsIndex}_maxProcessingRate(){return null!==this._parent?Math.min(this._maxProcessing,this._parent._maxProcessingRate()):Math.min(this._maxProcessing,this._maxQueryRate())}_maxQueryRate(){return null!==this._parent?Math.max(this._maxQuery,this._parent._maxQueryRate()):this._maxQuery}nativeCapabilities(){return this._parent.nativeCapabilities()}get _hasCachedFeatures(){return null!=this._allFeatures}async queryAll(e){null==this._allFeatures&&(this._allFeatures=this._queryAll().then(e=>(0,p.N5)(e)));const t=(await this._allFeatures)();return null==e||e===a._?t:async function*(){for await(const r of t)(0,n.dZ)(e),yield r}()}async databaseType(){if(7===this._databaseType){if(null!==s.A.applicationCache){const e=s.A.applicationCache.getDatabaseType(this._cacheableFeatureSetSourceKey());if(null!==e)return e}if(null!==this._databaseTypeProbed)return this._databaseTypeProbed;try{this._databaseTypeProbed=this._getDatabaseTypeImpl(),null!==s.A.applicationCache&&s.A.applicationCache.setDatabaseType(this._cacheableFeatureSetSourceKey(),this._databaseTypeProbed)}catch(e){throw null!==s.A.applicationCache&&s.A.applicationCache.clearDatabaseType(this._cacheableFeatureSetSourceKey()),e}return this._databaseTypeProbed}return this._databaseType}async _getDatabaseTypeImpl(){const e=[{dbType:2,probeSql:"(CAST( '2015-01-01' as DATETIME) = CAST( '2015-01-01' as DATETIME)) AND OBJECTID<0"},{dbType:3,probeSql:"(TO_DATE('2003-11-18','YYYY-MM-DD') = TO_DATE('2003-11-18','YYYY-MM-DD')) AND OBJECTID<0"},{dbType:1,probeSql:"(date '2015-01-01 10:10:10' = date '2015-01-01 10:10:10') AND OBJECTID<0"}];for(const t of e)if(!0===await this._runDatabaseProbe(t.probeSql))return t.dbType;return 1}_cacheableFeatureSetSourceKey(){return"MUSTBESET"}async _runDatabaseProbe(e){if(null!==this._parent)return this._parent._runDatabaseProbe(e);throw new n.dr("NotImplemented")}isTable(){return this._parent?.isTable()??!1}first(e){return this.iterator(e).next()}async isEmpty(e){return this._totalCount>=0?0===this._totalCount:null==await this.first(e)}async calculateStatistic(e,t,r,a){await this._ensureLoaded();let s=await this.queryStat({stat:e,field:t,limit:r,abortSignal:a});return!1===s.calculated&&(s=await this._manualStat(e,t,r,a)),s.result}async _manualStat(e,t,r,a){let s=null;switch(e.toLowerCase()){case"count":{if(this._totalCount>=0)return{calculated:!0,result:this._totalCount};const e=await this.queryAll(a);let t=0;for await(const r of e)t+=r.length;return this._totalCount=t,{calculated:!0,result:t}}case"distinct":return s=await(0,h.dM)(this,t,r,a),{calculated:!0,result:s};case"avg":case"mean":return s=await(0,h.i2)(this,t,a),{calculated:!0,result:s};case"stdev":return s=await(0,h.b$)(this,t,a),{calculated:!0,result:s};case"variance":return s=await(0,h.GV)(this,t,a),{calculated:!0,result:s};case"sum":return s=await(0,h.cz)(this,t,a),{calculated:!0,result:s};case"min":return s=await(0,h.jk)(this,t,a),{calculated:!0,result:s};case"max":return s=await(0,h.T9)(this,t,a),{calculated:!0,result:s};default:return{calculated:!0,result:0}}}iterator(e){return new u(this,e)}async sumArea(e,t,r){const a=this.iterator(r);let s,n=0;for(;null!=(s=await a.next());)null!=s.geometry&&(n+=null!=t?await(0,d.C)("geodeticArea",[s.geometry.toJSON(),e,t]):await(0,d.C)("area",[s.geometry.toJSON(),e]));return n}async sumLength(e,t,r){const a=this.iterator(r);let s,n=0;for(;null!=(s=await a.next());)null!=s.geometry&&(n+=null!=t?await(0,d.C)("geodeticLength",[s.geometry.toJSON(),e,t]):await(0,d.C)("length",[s.geometry.toJSON(),e]));return n}async count(e){return await this.load(),this.calculateStatistic("count",f.A.create("1",{fieldsIndex:this.getFieldsIndex(),timeZone:this.dateFieldsTimeZoneDefaultUTC}),-1,e??a._)}castToText(e=!1){return"object, FeatureSet"}queryAttachments(e,t,r,a,s){return this._parent.queryAttachments(e,t,r,a,s)}serviceUrl(){return this._parent.serviceUrl()}subtypeMetadata(){return this.subtypeField&&this.subtypes?{subtypeField:this.subtypeField,subtypes:this.subtypes?this.subtypes.map(e=>({name:e.name,code:e.code})):[]}:this.typeIdField?{subtypeField:this.typeIdField,subtypes:this.types?this.types.map(e=>({name:e.name,code:e.id})):[]}:null}relationshipMetadata(){return this._parent.relationshipMetadata()}get gdbVersion(){return this._parent?this._parent.gdbVersion:""}schema(){const e=[];for(const t of this.fields)e.push((0,c.nE)(t));return{objectIdField:this.objectIdField,globalIdField:this.globalIdField,geometryType:void 0===c.yT[this.geometryType]?"esriGeometryNull":c.yT[this.geometryType],fields:e}}async convertToText(e,t){if("schema"===e)return await this._ensureLoaded(),JSON.stringify(this.schema());if("featureset"===e){await this._ensureLoaded();const e=[];for await(const r of await this.queryAll(t))for(const t of r){const r={geometry:t.geometry?t.geometry.toJSON():null,attributes:t.attributes};null!==r.geometry&&r.geometry.spatialReference&&delete r.geometry.spatialReference,e.push(r)}return JSON.stringify({...this.schema(),features:e,spatialReference:this.spatialReference.toJSON()})}return this.castToText()}getFeatureByObjectId(e,t){return this._parent.getFeatureByObjectId(e,t)}getOwningSystemUrl(){return this._parent.getOwningSystemUrl()}getIdentityUser(){return this._parent.getIdentityUser()}getRootFeatureSet(){return this._parent.getRootFeatureSet()}getDataSourceFeatureSet(){return null!==this._parent?this._parent.getDataSourceFeatureSet():this}castAsJson(e=null){return"keeptype"===e?.featureset?this:"none"===e?.featureset?null:{type:"FeatureSet"}}async castAsJsonAsync(e=null,t=null){if("keeptype"===t?.featureset)return this;if("schema"===t?.featureset)return await this._ensureLoaded(),JSON.parse(JSON.stringify(this.schema()));if("none"===t?.featureset)return null;await this._ensureLoaded();const r=[];for await(const a of await this.queryAll(e))for(const e of a){const a={geometry:e.geometry?!0===t?.keepGeometryType?e.geometry:e.geometry.toJSON():null,attributes:e.attributes};null!==a.geometry&&a.geometry.spatialReference&&!0!==t?.keepGeometryType&&delete a.geometry.spatialReference,r.push(a)}return{...this.schema(),features:r,spatialReference:!0===t?.keepGeometryType?this.spatialReference:this.spatialReference?.toJSON()}}fieldTimeZone(e){return this.getFieldsIndex().getTimeZone(e)}get preferredTimeZone(){return this._parent?.preferredTimeZone??null}get dateFieldsTimeZone(){return this._parent?.dateFieldsTimeZone??null}get dateFieldsTimeZoneDefaultUTC(){return this.datesInUnknownTimezone?"unknown":this.dateFieldsTimeZone||"UTC"}get datesInUnknownTimezone(){return this._parent.datesInUnknownTimezone}get editFieldsInfo(){return this._parent?.editFieldsInfo??null}get timeInfo(){return this._parent?.timeInfo??null}getFeatureSetInfo(){return this._parent?this._parent.getFeatureSetInfo():Promise.resolve(null)}}class b extends T{constructor(){super(...arguments),this._parent=null}getRootFeatureSet(){return this}}},23732:(e,t,r)=>{r.d(t,{A:()=>a});class a{static{this.applicationCache=null}constructor(){this._databaseTypeMetaData={},this._layerInfo={}}clearDatabaseType(e){void 0===this._databaseTypeMetaData[e]&&delete this._databaseTypeMetaData[e]}getDatabaseType(e){return"MUSTBESET"===e||void 0===this._databaseTypeMetaData[e]?null:this._databaseTypeMetaData[e]}setDatabaseType(e,t){this._databaseTypeMetaData[e]=t}getLayerInfo(e){return void 0===this._layerInfo[e]?null:this._layerInfo[e]}setLayerInfo(e,t){this._layerInfo[e]=t}clearLayerInfo(e){void 0!==this._layerInfo[e]&&delete this._layerInfo[e]}}},50145:(e,t,r)=>{r.d(t,{Dp:()=>c,GV:()=>f,T9:()=>d,b$:()=>y,cz:()=>m,dM:()=>T,i2:()=>p,jk:()=>h});var a=r(87449),s=(r(33325),r(80609)),n=r(44729),i=r(55612),l=r(15032);function o(e){let t=0;for(let r=0;r<e.length;r++)t+=e[r];return t/e.length}function u(e){const t=o(e);let r=0;for(let a=0;a<e.length;a++)r+=(t-e[a])**2;return r/(e.length-1)}function c(e){switch(e.toLowerCase()){case"distinct":return"distinct";case"avg":case"mean":return"avg";case"min":return"min";case"sum":return"sum";case"max":return"max";case"stdev":case"stddev":return"stddev";case"var":case"variance":return"var";case"count":return"count"}return null}async function h(e,t,r){const a=await g(e,t,r);return 0===a.length?null:Math.min.apply(Math,a)}async function d(e,t,r){const a=await g(e,t,r);return 0===a.length?null:Math.max.apply(Math,a)}async function p(e,t,r){let a="";t&&!(0,s.DA)(t)&&(a=(0,s.IY)(t,e.fields));const n=await g(e,t,r);if(0===n.length)return null;const i=o(n);return null===i?i:"integer"===a?function(e){return e=+e,isFinite(e)?e-e%1||(e<0?-0:0===e?e:0):e}(i):i}async function f(e,t,r){const a=await g(e,t,r);return 0===a.length?null:u(a)}async function y(e,t,r){const a=await g(e,t,r);return 0===a.length?null:Math.sqrt(u(a))}async function m(e,t,r){const a=await g(e,t,r);return 0===a.length?null:function(e){let t=0;for(let r=0;r<e.length;r++)t+=e[r];return t}(a)}async function g(e,t,r){const s=await e.queryAll(r),o=[],u={ticker:0};for await(const e of s){if(u.ticker+=e.length,u.ticker>=100&&(u.ticker=0,await new Promise(e=>{setTimeout(e,0)})),r?.aborted)throw new a.dr("Cancelled");for(const r of e){const e=t?.calculateValue(r);null===e||(o[o.length]=e instanceof n.n||e instanceof l.k?e.toNumber():e instanceof i.g?e.toMilliseconds():e)}}return o}async function T(e,t,r=1e3,s=null){if(null==t)return[];const o=await e.queryAll(s),u=[],c=new Set,h={ticker:0};for await(const e of o){if(h.ticker+=e.length,h.ticker>=100&&(h.ticker=0,await new Promise(e=>{setTimeout(e,0)})),s?.aborted)throw new a.dr("Cancelled");for(const a of e){const e=t.calculateValue(a);let s=e;if(e instanceof n.n?s="!!DATEONLY!!-"+e.toString():e instanceof i.g?s="!!TSOFFSETONLY!!-"+e.toString():e instanceof l.k?s="!!TIMEONLY!!-"+e.toString():e instanceof Date&&(s="!!DATE!!-"+e.toString()),null!=e&&(c.has(s)||(u.push(e),c.add(s))),u.length>=r&&-1!==r)return u}}return u}},71163:(e,t,r)=>{r.d(t,{C:()=>o});var a=r(29953);let s,n,i=!1;function l(){return s??=(0,a.ho)("arcadeGeometryOperatorsWorker").then(e=>{n=e,i=!0,s=void 0})}async function o(e,t){return i?n.apply("invokeGeometryOp",[e,t]):(await l(),o(e,t))}},80609:(e,t,r)=>{r.d(t,{C6:()=>_,DA:()=>E,F1:()=>T,F6:()=>y,IY:()=>w,Ju:()=>F,Kb:()=>p,Mi:()=>c,Nf:()=>g,R8:()=>m,YY:()=>u,bD:()=>h,bm:()=>b,kg:()=>d,oj:()=>C});var a=r(66131),s=r(33325),n=r(1262),i=r(15032),l=r(88368),o=r(28097);function u(e,t){return f(e?.parseTree,t,e?.parameters)}function c(e,t,r){return f(e,t,r)}function h(e,t,r,a){const s=f(e.parseTree,0,e.parameters,t,r);return l.A.create(s,{fieldsIndex:a,timeZone:e.timeZone,currentUser:e.currentUser})}function d(e,t,r="AND"){return l.A.create("(("+u(e,0)+")"+r+"("+u(t,0)+"))",{fieldsIndex:e.fieldsIndex,timeZone:e.timeZone,currentUser:e.currentUser})}function p(e){return!0===e.delimited?`"${e.column.split('"').join('""')}"`:e.column}function f(e,t,r,a=null,i=null){let l,o,u,c;switch(e.type){case"interval":return C(f(e.value,t,r,a,i),e.qualifier,e.op);case"case-expression":{let s=" CASE ";"simple"===e.format&&(s+=f(e.operand,t,r,a,i));for(let n=0;n<e.clauses.length;n++)s+=" WHEN "+f(e.clauses[n].operand,t,r,a,i)+" THEN "+f(e.clauses[n].value,t,r,a,i);return null!==e.else&&(s+=" ELSE "+f(e.else,t,r,a,i)),s+=" END ",s}case"parameter":{const a=r[e.value.toLowerCase()];if("string"==typeof a)return"'"+r[e.value.toLowerCase()].toString().replaceAll("'","''")+"'";if((0,s.$P)(a))return b(a,t);if((0,s.Lk)(a))return b(a,t);if((0,s.eg)(a))return T(a,t);if((0,s.rX)(a))return m(a,t);if((0,s.f0)(a))return g(a,t);if(Array.isArray(a)){const e=[];for(let r=0;r<a.length;r++)"string"==typeof a[r]?e.push("'"+a[r].toString().replaceAll("'","''")+"'"):(0,s.$P)(a[r])||(0,s.Lk)(a[r])?e.push(b(a[r],t)):(0,s.eg)(a[r])?e.push(T(a[r],t)):(0,s.rX)(a[r])?e.push(m(a[r],t)):(0,s.f0)(a[r])?e.push(g(a[r],t)):e.push(a[r].toString());return e}return a.toString()}case"expression-list":o=[];for(const s of e.value)o.push(f(s,t,r,a,i));return o;case"unary-expression":return" ( NOT "+f(e.expr,t,r,a,i)+" ) ";case"binary-expression":switch(e.operator){case"AND":return" ("+f(e.left,t,r,a,i)+" AND "+f(e.right,t,r,a,i)+") ";case"OR":return" ("+f(e.left,t,r,a,i)+" OR "+f(e.right,t,r,a,i)+") ";case"IS":if("null"!==e.right.type)throw new n.L("UnsupportedIsRhs");return" ("+f(e.left,t,r,a,i)+" IS NULL )";case"ISNOT":if("null"!==e.right.type)throw new n.L("UnsupportedIsRhs");return" ("+f(e.left,t,r,a,i)+" IS NOT NULL )";case"IN":return l=[],"expression-list"===e.right.type?(l=f(e.right,t,r,a,i)," ("+f(e.left,t,r,a,i)+" IN ("+l.join(",")+")) "):(c=f(e.right,t,r,a,i),Array.isArray(c)?" ("+f(e.left,t,r,a,i)+" IN ("+c.join(",")+")) ":" ("+f(e.left,t,r,a,i)+" IN ("+c+")) ");case"NOT IN":return l=[],"expression-list"===e.right.type?(l=f(e.right,t,r,a,i)," ("+f(e.left,t,r,a,i)+" NOT IN ("+l.join(",")+")) "):(c=f(e.right,t,r,a,i),Array.isArray(c)?" ("+f(e.left,t,r,a,i)+" NOT IN ("+c.join(",")+")) ":" ("+f(e.left,t,r,a,i)+" NOT IN ("+c+")) ");case"BETWEEN":return u=f(e.right,t,r,a,i)," ("+f(e.left,t,r,a,i)+" BETWEEN "+u[0]+" AND "+u[1]+" ) ";case"NOTBETWEEN":return u=f(e.right,t,r,a,i)," ("+f(e.left,t,r,a,i)+" NOT BETWEEN "+u[0]+" AND "+u[1]+" ) ";case"LIKE":return""!==e.escape?" ("+f(e.left,t,r,a,i)+" LIKE "+f(e.right,t,r,a,i)+" ESCAPE '"+e.escape+"') ":" ("+f(e.left,t,r,a,i)+" LIKE "+f(e.right,t,r,a,i)+") ";case"NOT LIKE":return""!==e.escape?" ("+f(e.left,t,r,a,i)+" NOT LIKE "+f(e.right,t,r,a,i)+" ESCAPE '"+e.escape+"') ":" ("+f(e.left,t,r,a,i)+" NOT LIKE "+f(e.right,t,r,a,i)+") ";case"<>":case"<":case">":case">=":case"<=":case"=":case"*":case"-":case"+":case"/":return" ("+f(e.left,t,r,a,i)+" "+e.operator+" "+f(e.right,t,r,a,i)+") ";case"||":return" ("+f(e.left,t,r,a,i)+" "+(2===t?"+":e.operator)+" "+f(e.right,t,r,a,i)+") "}throw new n.L("UnsupportedOperator",{operator:e.operator});case"null":return"null";case"boolean":return!0===e.value?"1":"0";case"string":return"'"+e.value.toString().replaceAll("'","''")+"'";case"timestamp":return`timestamp '${e.value}'`;case"date":return`date '${e.value}'`;case"time":return`time '${e.value}'`;case"number":return e.value.toString();case"current-time":return _(e.mode,t);case"current-user":return"CURRENT_USER";case"column-reference":return a&&a.toLowerCase()===e.column.toLowerCase()?"("+i+")":p(e);case"data-type":return e.value;case"function":{const s=f(e.args,t,r,a,i);return y(e.name,s,t)}}throw new n.L("UnsupportedSyntax",{node:e.type})}function y(e,t,r){switch(e.toLowerCase().trim()){case"cos":case"sin":case"tan":case"cosh":case"tanh":case"sinh":case"acos":case"asin":case"atan":case"floor":case"log10":case"log":case"abs":if(1!==t.length)throw new n.L("InvalidFunctionParameters",{function:e.toLowerCase().trim()});return`${e.toUpperCase().trim()}(${t[0]})`;case"ceiling":case"ceil":if(1!==t.length)throw new n.L("InvalidFunctionParameters",{function:"ceiling"});return"CEILING("+t[0]+")";case"mod":case"power":case"nullif":if(2!==t.length)throw new n.L("InvalidFunctionParameters",{function:e.toLowerCase().trim()});return`${e.toUpperCase().trim()}(${t[0]},${t[1]})`;case"round":if(2===t.length)return"ROUND("+t[0]+","+t[1]+")";if(1===t.length)return"ROUND("+t[0]+")";throw new n.L("InvalidFunctionParameters",{function:"round"});case"truncate":if(t.length<1||t.length>2)throw new n.L("InvalidFunctionParameters",{function:"truncate"});return 2===r?"ROUND("+t[0]+(1===t.length?"0":","+t[1])+",1)":"TRUNCATE("+t[0]+(1===t.length?")":","+t[1]+")");case"char_length":case"len":if(1!==t.length)throw new n.L("InvalidFunctionParameters",{function:"char_length"});switch(r){case 2:return"LEN("+t[0]+")";case 3:return"LENGTH("+t[0]+")";default:return"CHAR_LENGTH("+t[0]+")"}case"coalesce":case"concat":{if(t.length<1)throw new n.L("InvalidFunctionParameters",{function:e.toLowerCase()});let r=e.toUpperCase().trim()+"(";for(let e=0;e<t.length;e++)0!==e&&(r+=","),r+=t[e];return r+=")",r}case"lower":case"lcase":if(1!==t.length)throw new n.L("InvalidFunctionParameters",{function:"lower"});return"LOWER("+t[0]+")";case"upper":case"ucase":if(1!==t.length)throw new n.L("InvalidFunctionParameters",{function:"upper"});return"UPPER("+t[0]+")";case"substring":{let e="";switch(r){case 3:return e="SUBSTR("+t[0]+","+t[1],3===t.length&&(e+=","+t[2]),e+=")",e;case 2:return e=3===t.length?"SUBSTRING("+t[0]+","+t[1]+","+t[2]+")":"SUBSTRING("+t[0]+", "+t[1]+", LEN("+t[0]+") - "+t[1]+")",e;default:return e="SUBSTRING("+t[0]+" FROM "+t[1],3===t.length&&(e+=" FOR "+t[2]),e+=")",e}}case"extract":return"EXTRACT("+t[0].replaceAll("'","")+" FROM "+t[1]+")";case"cast":{let e="";switch(r){case 3:switch(t[1].type){case"date":e="DATE";break;case"float":e="DOUBLE";break;case"integer":e="INTEGER";break;case"real":e="REAL";break;case"smallint":e="SMALLINT";break;case"timestamp":e="TIMESTAMP";break;case"varchar":e="VARCHAR("+t[1].size.toString()+")"}return`CAST(${t[0]} AS ${e})`;case 4:switch(t[1].type){case"date":e="DATE";break;case"float":e="DOUBLE PRECISION";break;case"integer":e="INT";break;case"real":e="REAL";break;case"smallint":e="SMALLINT";break;case"timestamp":e="TIMESTAMP";break;case"varchar":e="VARCHAR("+t[1].size.toString()+")"}return`CAST(${t[0]} AS ${e})`;case 2:switch(t[1].type){case"date":e="DATE";break;case"float":e="FLOAT";break;case"integer":e="INT";break;case"real":e="REAL";break;case"smallint":e="SMALLINT";break;case"timestamp":e="DATETIME";break;case"varchar":e="VARCHAR("+t[1].size.toString()+")"}return`CAST(${t[0]} AS ${e})`;default:switch(t[1].type){case"date":e="DATE";break;case"float":e="FLOAT";break;case"integer":e="INTEGER";break;case"real":e="REAL";break;case"smallint":e="SMALLINT";break;case"timestamp":e="TIMESTAMP";break;case"varchar":e="VARCHAR("+t[1].size.toString()+")"}return`CAST(${t[0]} AS ${e})`}}}throw new n.L("InvalidFunctionParameters",{function:e})}function m(e,t){const r=e.toDateTime(),a=0===r.hour&&0===r.minute&&0===r.second&&0===r.millisecond;switch(t){case 6:case 0:case 1:return a?`date '${r.toFormat("yyyy-LL-dd")}'`:`timestamp '${r.toFormat("yyyy-LL-dd HH:mm:ss")}'`;case 3:return a?`TO_DATE('${r.toFormat("yyyy-LL-dd")}','YYYY-MM-DD')`:`TO_DATE('${r.toFormat("yyyy-LL-dd HH:mm:ss")}','YYYY-MM-DD HH24:MI:SS')`;case 2:return`'${r.toFormat(a?"yyyy-LL-dd":"yyyy-LL-dd HH:mm:ss")}'`;case 5:return`#${r.toFormat(a?"LL-dd-yyyy":"LL-dd-yyyy HH:mm:ss")}#`;case 4:return`TIMESTAMP '${r.toFormat(a?"yyyy-LL-dd":"yyyy-LL-dd HH:mm:ss")}'`;default:return`timestamp '${r.toFormat("yyyy-LL-dd HH:mm:ss")}'`}}function g(e,t){switch(t){case 6:case 0:case 1:default:return e.toSQLWithKeyword();case 3:return`TO_DATE('${e.toFormat("Y-MM-DD")}'`;case 2:return`'${e.toFormat("Y-MM-DD")}'`;case 5:return`#${e.toFormat("Y-MM-DD")}#`;case 4:return`TIMESTAMP '${e.toFormat("Y-MM-DD")}'`}}function T(e,t){switch(e instanceof i.k&&(e=e.toStorageString()),t){case 3:return`TO_DATE('${e}', 'HH24:MI:SS')`;case 2:return`'${e}'`;default:return`time '${e}'`}}function b(e,t){return m(a.lY.dateTimeToArcadeDate((0,s.Lk)(e)?e:o.c9.fromJSDate(e)),t)}function _(e,t){switch(t){case 6:case 0:case 1:case 3:case 5:default:return"date"===e?"CURRENT_DATE":"time"===e?"CURRENT_TIME":"CURRENT_TIMESTAMP";case 2:return"date"===e?"CAST(GETDATE() AS DATE)":"time"===e?"CAST(GETDATE() AS TIME)":"GETDATE()";case 4:return"date"===e?"CURRENT_DATE":"time"===e?"LOCALTIME":"CURRENT_TIMESTAMP"}}function w(e,t,r={}){const a={},s={},n={esriFieldTypeSmallInteger:"integer",esriFieldTypeInteger:"integer",esriFieldTypeBigInteger:"integer",esriFieldTypeSingle:"double",esriFieldTypeDouble:"double",esriFieldTypeString:"string",esriFieldTypeTimeOnly:"time-only",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimestampOffset:"timestamp-offset",esriFieldTypeDate:"date",esriFieldTypeOID:"integer",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"guid",oid:"integer",long:"integer","small-integer":"integer",integer:"integer","big-integer":"integer",single:"double","time-only":"time-only","date-only":"date-only","timestamp-offset":"timestemp-offset",double:"double",date:"date",guid:"guid","global-id":"guid",string:"string"};for(const e of t){const t=e.type?n[e.type]:void 0;a[e.name.toLowerCase()]=void 0===t?"":t}for(const e in r){const t=n[r[e]];s[e.toLowerCase()]=void 0===t?"":t}switch(I(a,e.parseTree,e.parameters,s)){case"double":return"double";case"integer":return"integer";case"date":return"date";case"date-only":return"date-only";case"time-only":return"time-only";case"timestamp-offset":return"timestamp-offset";case"string":return"string";case"global-id":case"guid":return"guid"}return""}function I(e,t,r,a){let i;switch(t.type){case"interval":return"integer";case"case-expression":{const s=[];if("simple"===t.format){for(let n=0;n<t.clauses.length;n++)s.push(I(e,t.clauses[n].value,r,a));null!==t.else&&s.push(I(e,t.else,r,a))}else{for(let n=0;n<t.clauses.length;n++)s.push(I(e,t.clauses[n].value,r,a));null!==t.else&&s.push(I(e,t.else,r,a))}return A(s)}case"parameter":{const e=a[t.value.toLowerCase()];if(void 0===e&&r){const e=r[t.value.toLowerCase()];if(void 0===e)return"";if(null===e)return"";if("string"==typeof e||e instanceof String)return"string";if("boolean"==typeof e)return"boolean";if((0,s.$P)(e))return"date";if((0,s.rX)(e))return"date";if((0,s.f0)(e))return"date-only";if((0,s.eg)(e))return"time-only";if("number"==typeof e)return e%1==0?"integer":"double"}return void 0===e?"":e}case"expression-list":{const s=[];for(const n of t.value)s.push(I(e,n,r,a));return s}case"unary-expression":return"boolean";case"binary-expression":switch(t.operator){case"AND":case"OR":case"IN":case"NOT IN":case"BETWEEN":case"NOTBETWEEN":case"LIKE":case"NOT LIKE":case"<>":case"<":case">":case">=":case"<=":case"=":return"boolean";case"IS":case"ISNOT":if("null"!==t.right.type)throw new n.L("UnsupportedIsRhs");return"boolean";case"*":case"-":case"+":case"/":return A([I(e,t.left,r,a),I(e,t.right,r,a)]);case"||":return"string";default:throw new n.L("UnsupportedOperator",{operator:t.operator})}case"null":return"";case"boolean":return"boolean";case"string":return"string";case"number":return null===t.value?"":t.value%1==0?"integer":"double";case"date":return"date";case"timestamp":return t.withtimezone?"timestamp-offset":"date";case"time":return"time-only";case"current-time":return"time"===t.mode?"time-only":"date";case"current-user":return"string";case"column-reference":{const r=e[t.column.toLowerCase()];return void 0===r?"":r}case"function":switch(t.name.toLowerCase()){case"cast":switch(t.args?.value[1]?.value.type??""){case"integer":case"smallint":return"integer";case"real":case"float":return"double";case"date":case"timestamp":return!0===t.args?.value[1]?.value?.withtimezone?"timestamp-offset":"date";case"time":return"time-only";case"varchar":return"string";default:return""}case"position":case"extract":case"char_length":case"mod":return"integer";case"round":if(i=I(e,t.args,r,a),Array.isArray(i)){if(i.length<=0)return"double";i=i[0]}return i;case"sign":return"integer";case"ceiling":case"floor":case"abs":return i=I(e,t.args,r,a),Array.isArray(i)&&(i=A(i)),"integer"===i||"double"===i?i:"double";case"area":case"length":case"log":case"log10":case"sin":case"cos":case"tan":case"asin":case"acos":case"atan":case"cosh":case"sinh":case"tanh":case"power":return"double";case"substring":case"trim":case"concat":case"lower":case"upper":return"string";case"truncate":return"double";case"nullif":case"coalesce":return i=I(e,t.args,r,a),Array.isArray(i)?i.length>0?i[0]:"":i}return""}throw new n.L("UnsupportedSyntax",{node:t.type})}const S={boolean:1,string:2,integer:3,double:4,date:5};function A(e){if(e){let t="";for(const r of e)""!==r&&(t=""===t||S[t]<S[r]?r:t);return t}return""}function F(e,t){return L(e.parseTree,t)}function E(e){return"column-reference"===e?.parseTree.type}function L(e,t){if(null==e)return!1;switch(e.type){case"when-clause":return L(e.operand,t)||L(e.value,t);case"case-expression":for(const r of e.clauses)if(L(r,t))return!0;return!("simple"!==e.format||!L(e.operand,t))||!(null===e.else||!L(e.else,t));case"parameter":case"null":case"boolean":case"date":case"timestamp":case"time":case"string":case"number":return!1;case"expression-list":for(const r of e.value)if(L(r,t))return!0;return!1;case"unary-expression":return L(e.expr,t);case"binary-expression":return L(e.left,t)||L(e.right,t);case"column-reference":return t.toLowerCase()===e.column.toLowerCase();case"function":return L(e.args,t)}return!1}function N(e){let t="";return t+=e.period.toUpperCase(),t}function C(e,t,r){let a="";return a="interval-period"===t.type?N(t):N(t.start)+" TO "+N(t.end),"INTERVAL "+r+" "+e+" "+a}},87449:(e,t,r)=>{r.d(t,{dZ:()=>i,dr:()=>n});var a=r(799);const s={Cancelled:"Cancelled",InvalidStatResponse:"Invalid statistics response from service",InvalidRequest:"Invalid request",RequestFailed:"Request failed - {reason}",MissingFeatures:"Missing features",AggregationFieldNotFound:"Aggregation field not found",DataElementsNotFound:"Data elements not found on service",NeverReach:"Encountered unreachable logic",NotImplemented:"Not implemented"};class n extends Error{constructor(e,t){super((0,a.HC)(s[e],t)),this.declaredRootClass="esri.arcade.featureset.support.featureseterror",Error.captureStackTrace&&Error.captureStackTrace(this,n)}}function i(e){if(null!=e&&e?.aborted)throw new n("Cancelled")}}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3103],{33103:(t,e,r)=>{r.r(e),r.d(e,{executeAttributeBinsQuery:()=>S});var n=r(2272),s=r(11254),i=r(84952),u=r(65864),a=r(17136),o=r(21325),l=r(10536);function c(t){const e=t.geometry,r=t.toJSON(),n=r;let s,i,a;if(null!=e&&(i=e.spatialReference,a=(0,o.YX)(i),n.geometryType=(0,u.$B)(e),n.geometry=JSON.stringify(e),n.inSR=a),r.outSR?(n.outSR=(0,o.YX)(r.outSR),s=t.outSpatialReference):e&&(n.outSR=n.inSR,s=i),n.bin&&=JSON.stringify(n.bin),n.quantizationParameters&&=JSON.stringify(n.quantizationParameters),n.outStatistics&&=JSON.stringify(n.outStatistics),n.outTimeReference&&=JSON.stringify(n.outTimeReference),r.timeExtent){const t=r.timeExtent,{start:e,end:s}=t;null==e&&null==s||(n.time=e===s?e:`${e??"null"},${s??"null"}`),delete r.timeExtent}return t.defaultSpatialReference&&(0,o.aI)(i,s)&&(n.defaultSR=n.inSR,delete n.inSR,delete n.outSR),n}var f=r(37745),y=r(14575);async function S(t,e,r){const{data:u}=await async function(t,e,r){return null!=e.timeExtent&&e.timeExtent.isEmpty?{data:{features:[]}}:await async function(t,e,r={}){const n="string"==typeof t?(0,i.An)(t):t,u=e.geometry?[e.geometry]:[],o=await(0,a.el)(u,null,{signal:r.signal}),f=o?.[0];null!=f&&((e=e.clone()).geometry=f);const y=(0,l.z)({...n.query,f:"json",...c(e)});return(0,s.A)((0,i.fj)(n.path,"queryBins"),{...r,query:{...y,...r.query}})}(t,e,r)}((0,n.Dl)(t),y.default.from(e),r);return f.A.fromJSON(u)}},37745:(t,e,r)=>{r.d(e,{A:()=>S});var n,s=r(31635),i=r(52106),u=r(69540),a=r(4718),o=r(10107),l=(r(44208),r(53966),r(64108));let c=class extends((0,u.OU)(i.A)){static{n=this}constructor(t){super(t),this.stackedAttributes=null}cloneShallow(){return new n(Object.assign({stackedAttributes:this.stackedAttributes},super.cloneShallow()))}toJSON(){return{...super.toJSON(),stackedAttributes:(0,a.o8)(this.stackedAttributes)}}};(0,s.Cg)([(0,o.MZ)()],c.prototype,"stackedAttributes",void 0),c=n=(0,s.Cg)([(0,l.$)("esri.AttributeBinsGraphic")],c),r(87811);var f=r(36005),y=r(22671);let S=class extends((0,u.OU)(y.A)){constructor(t){super(t),this.features=[]}readFeatures(t,e){return this.readFeaturesWithClass(t,e,c)}};(0,s.Cg)([(0,o.MZ)({type:[c],json:{write:!0}})],S.prototype,"features",void 0),(0,s.Cg)([(0,f.w)("features")],S.prototype,"readFeatures",null),S=(0,s.Cg)([(0,l.$)("esri.rest.support.AttributeBinsFeatureSet")],S)}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3103],{33103:(t,e,r)=>{r.r(e),r.d(e,{executeAttributeBinsQuery:()=>S});var n=r(2272),s=r(11254),i=r(84952),u=r(65864),a=r(17136),o=r(21325),l=r(10536);function c(t){const e=t.geometry,r=t.toJSON(),n=r;let s,i,a;if(null!=e&&(i=e.spatialReference,a=(0,o.YX)(i),n.geometryType=(0,u.$B)(e),n.geometry=JSON.stringify(e),n.inSR=a),r.outSR?(n.outSR=(0,o.YX)(r.outSR),s=t.outSpatialReference):e&&(n.outSR=n.inSR,s=i),n.bin&&=JSON.stringify(n.bin),n.quantizationParameters&&=JSON.stringify(n.quantizationParameters),n.outStatistics&&=JSON.stringify(n.outStatistics),n.outTimeReference&&=JSON.stringify(n.outTimeReference),r.timeExtent){const t=r.timeExtent,{start:e,end:s}=t;null==e&&null==s||(n.time=e===s?e:`${e??"null"},${s??"null"}`),delete r.timeExtent}return t.defaultSpatialReference&&(0,o.aI)(i,s)&&(n.defaultSR=n.inSR,delete n.inSR,delete n.outSR),n}var f=r(37745),y=r(14575);async function S(t,e,r){const{data:u}=await async function(t,e,r){return null!=e.timeExtent&&e.timeExtent.isEmpty?{data:{features:[]}}:await async function(t,e,r={}){const n="string"==typeof t?(0,i.An)(t):t,u=e.geometry?[e.geometry]:[],o=await(0,a.el)(u,null,{signal:r.signal}),f=o?.[0];null!=f&&((e=e.clone()).geometry=f);const y=(0,l.z)({...n.query,f:"json",...c(e)});return(0,s.A)((0,i.fj)(n.path,"queryBins"),{...r,query:{...y,...r.query}})}(t,e,r)}((0,n.Dl)(t),y.default.from(e),r);return f.A.fromJSON(u)}},37745:(t,e,r)=>{r.d(e,{A:()=>S});var n,s=r(31635),i=r(52106),u=r(4718),a=r(10107),o=(r(44208),r(53966),r(64108));let l=class extends i.A{static{n=this}constructor(t){super(t),this.stackedAttributes=null}cloneShallow(){return new n(Object.assign({stackedAttributes:this.stackedAttributes},super.cloneShallow()))}toJSON(){return{...super.toJSON(),stackedAttributes:(0,u.o8)(this.stackedAttributes)}}};(0,s.Cg)([(0,a.MZ)()],l.prototype,"stackedAttributes",void 0),l=n=(0,s.Cg)([(0,o.$)("esri.AttributeBinsGraphic")],l);var c=r(69540),f=(r(87811),r(36005)),y=r(22671);let S=class extends((0,c.OU)(y.A)){constructor(t){super(t),this.features=[]}readFeatures(t,e){return this.readFeaturesWithClass(t,e,l)}};(0,s.Cg)([(0,a.MZ)({type:[l],json:{write:!0}})],S.prototype,"features",void 0),(0,s.Cg)([(0,f.w)("features")],S.prototype,"readFeatures",null),S=(0,s.Cg)([(0,o.$)("esri.rest.support.AttributeBinsFeatureSet")],S)}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3549],{13069:(e,t,n)=>{n.d(t,{AG:()=>a,lk:()=>r,vD:()=>s,yS:()=>o});const i="randomUUID"in crypto;function r(){if(i)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 o(){return`{${r().toUpperCase()}}`}function s(){return`{${r()}}`}function a(e){const t=e.toUpperCase();return e.startsWith("{")?t:`{${t}}`}},41560:(e,t,n)=>{n.d(t,{Ch:()=>s,mW:()=>o});var i=n(34727),r=n(39516);function o(e,t){return{...t,filterMode:e.mode}}function s(e,t,n){const o=function(e){if("manual"===c(e))return null;const t=[Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY];for(const{minScale:n,maxScale:i}of e.filters)t[0]=Math.max(t[0],u(n)),t[1]=Math.min(t[1],f(i));return t}(e);if(o&&((0,i.gg)(t,o[0])||(0,i.ZH)(n,o[1])))return"";const s=Array.from(a(e,t,n)),l=function(e,t,n){if(0===e.length)return!0;const r=u(e.at(0)?.minScale),o=f(e.at(-1)?.maxScale);if((0,i.ZH)(r,t)||(0,i.gg)(o,n))return!0;for(let t=0;t<e.length-1;t++){const n=e[t],r=e[t+1];if((0,i.ZH)(u(r.minScale),f(n.maxScale)))return!0}return!1}(s,t,n)?"1=1":s.map(e=>e.where||"1=1").reduce((e,t)=>(0,r.IW)(e,t),"");return l&&"1=1"!==l?l:""}function*a(e,t,n){if("manual"===c(e)){const t=e.filters.find(t=>t.id===e.activeFilterId);t&&(yield t)}else{"object"==typeof t&&(t=t.scale);for(const i of e.filters)l(i.minScale,i.maxScale,t,n)&&(yield i)}}function l(e,t,n,r){return e=u(e),n=u(n),t=f(t),!(!(0,i.Sp)(n,e)&&(r??n)>e||(0,i.Hx)(t,n)||void 0!==r&&(0,i.Sp)(r,e))}function c(e){return"mode"in e?e.mode:e.filterMode}function u(e){return e||Number.POSITIVE_INFINITY}function f(e){return e||0}},46140:(e,t,n)=>{n.d(t,{R:()=>r});var i=n(49186);let r=class e{constructor(e,t,n=""){this.major=e,this.minor=t,this._context=n}lessThan(e,t){return this.major<e||e===this.major&&this.minor<t}greaterEqual(e,t){return!this.lessThan(e,t)}validate(e){if(this.major!==e.major){const t=this._context&&this._context+":",n=this._context&&this._context+" ";throw new i.A(t+"unsupported-version",`Required major ${n}version is '${this.major}', but got '\${version.major}.\${version.minor}'`,{version:e})}}clone(){return new e(this.major,this.minor,this._context)}static parse(t,n=""){const[r,o]=t.split("."),s=/^\s*\d+\s*$/;if(!r?.match||!s.test(r))throw new i.A((n&&n+":")+"invalid-version","Expected major version to be a number, but got '${version}'",{version:t});if(!o?.match||!s.test(o))throw new i.A((n&&n+":")+"invalid-version","Expected minor version to be a number, but got '${version}'",{version:t});const a=parseInt(r,10),l=parseInt(o,10);return new e(a,l,n)}}},67482:(e,t,n)=>{function i(e){return null!=a(e)||null!=s(e)}function r(e){return l.test(e)}function o(e){return a(e)??s(e)}function s(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let n=!0;if(u&&/\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=!c.test(e[i]),i++;n=!t}}return n}(t,e)?Number.isNaN(t.getTime())?null:t.getTime()-6e4*t.getTimezoneOffset():null}function a(e){const t=l.exec(e);if(!t?.groups)return null;const n=t.groups,i=+n.year,r=+n.month-1,o=+n.day,s=+(n.hours??"0"),a=+(n.minutes??"0"),c=+(n.seconds??"0");if(s>23)return null;if(a>59)return null;if(c>59)return null;const u=n.ms??"0",f=u?+u.padEnd(3,"0").slice(0,3):0;let d;if(n.isUTC||!n.offsetSign)d=Date.UTC(i,r,o,s,a,c,f);else{const e=+n.offsetHours,t=+n.offsetMinutes;d=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(i,r,o,s,a,c,f)}return Number.isNaN(d)?null:d}n.d(t,{Br:()=>r,Cq:()=>i,_U:()=>o});const l=/^(?:(?<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})))?$/,c=/^((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,u=!Number.isNaN(new Date("technology 10").getTime())},75321:(e,t,n)=>{n.d(t,{GA:()=>x,GL:()=>S,I:()=>P,J0:()=>N,Ki:()=>v,Px:()=>A,QE:()=>F,bV:()=>j,bW:()=>k,vJ:()=>T});var i=n(11254),r=n(49186),o=n(53966),s=n(84952),a=n(16930),l=n(21325),c=n(28735),u=n(90708),f=n(58512),d=n(85113),p=n(64714),m=n(82832),g=n(95466),y=n(98453),h=n(98623);const w=()=>o.A.getLogger("esri.layers.ogc.ogcFeatureUtils"),b="startindex",I=new Set([b,"offset"]),T="http://www.opengis.net/def/crs/",F=`${T}OGC/1.3/CRS84`;async function S(e,t,n={},o=5){const{links:a}=e,l=O(a,"items","application/geo+json")||O(a,"http://www.opengis.net/def/rel/ogc/1.0/items","application/geo+json");if(null==l)throw new r.A("ogc-feature-layer:missing-items-page","Missing items url");const{apiKey:c,customParameters:u,signal:f}=n,m=(0,s.s2)(l.href,e.landingPage.url),I={limit:o,...u,token:c},T=(0,s.a6)(m,I),{data:F}=await(0,i.A)(T,{signal:f,headers:{accept:"application/geo+json"}}),S=E(T,o,F.links)??b;(0,d.sO)(F);const j=F.numberMatched,A=(0,d.BM)(F,{geometryType:t.geometryType}),v=t.fields||A.fields||[],x=null!=t.hasZ?t.hasZ:A.hasZ,N=A.geometryType,k=t.objectIdField||A.objectIdFieldName||"OBJECTID";let P=t.timeInfo;const C=v.find(({name:e})=>e===k);if(C)C.editable=!1,C.nullable=!1;else{if(!A.objectIdFieldType)throw new r.A("ogc-feature-layer:missing-feature-id","Collection geojson require a feature id as a unique identifier");v.unshift({name:k,alias:k,type:"number"===A.objectIdFieldType?"esriFieldTypeOID":"esriFieldTypeString",editable:!1,nullable:!1})}if(k!==A.objectIdFieldName){const e=v.find(({name:e})=>e===A.objectIdFieldName);e&&(e.type="esriFieldTypeInteger")}v===A.fields&&A.unknownFields.length>0&&w().warn({name:"ogc-feature-layer:unknown-field-types",message:"Some fields types couldn't be inferred from the features and were dropped",details:{unknownFields:A.unknownFields}});for(const e of v){if(null==e.name&&(e.name=e.alias),null==e.alias&&(e.alias=e.name),"esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type&&(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable),!e.name)throw new r.A("ogc-feature-layer:invalid-field-name","field name is missing",{field:e});if(!y.m.jsonValues.includes(e.type))throw new r.A("ogc-feature-layer:invalid-field-type",`invalid type for field "${e.name}"`,{field:e})}if(P){const e=new g.A(v);if(P.startTimeField){const t=e.get(P.startTimeField);t?(P.startTimeField=t.name,t.type="esriFieldTypeDate"):P.startTimeField=null}if(P.endTimeField){const t=e.get(P.endTimeField);t?(P.endTimeField=t.name,t.type="esriFieldTypeDate"):P.endTimeField=null}if(P.trackIdField){const t=e.get(P.trackIdField);t?P.trackIdField=t.name:(P.trackIdField=null,w().warn({name:"ogc-feature-layer:invalid-timeInfo-trackIdField",message:"trackIdField is missing",details:{timeInfo:P}}))}P.timeReference||={timeZoneIANA:h.n$},P.startTimeField||P.endTimeField||(w().warn({name:"ogc-feature-layer:invalid-timeInfo",message:"startTimeField and endTimeField are missing",details:{timeInfo:P}}),P=void 0)}return{drawingInfo:N?(0,p.F0)(N):null,extent:G(e),geometryType:N,fields:v,hasZ:!!x,objectIdField:k,paginationParameter:S,timeInfo:P,featureCount:j}}async function j(e,t={}){const{links:n,url:o}=e,a=O(n,"data","application/json")||O(n,"http://www.opengis.net/def/rel/ogc/1.0/data","application/json");if(null==a)throw new r.A("ogc-feature-layer:missing-collections-page","Missing collections url");const{apiKey:l,customParameters:c,signal:u}=t,f=(0,s.s2)(a.href,o),{data:d}=await(0,i.A)(f,{signal:u,headers:{accept:"application/json"},query:{...c,token:l}});for(const t of d.collections)t.landingPage=e;return d}async function A(e,t={}){const{links:n,url:o}=e,a=O(n,"conformance","application/json")||O(n,"http://www.opengis.net/def/rel/ogc/1.0/conformance","application/json");if(null==a)throw new r.A("ogc-feature-layer:missing-conformance-page","Missing conformance url");const{apiKey:l,customParameters:c,signal:u}=t,f=(0,s.s2)(a.href,o),{data:d}=await(0,i.A)(f,{signal:u,headers:{accept:"application/json"},query:{...c,token:l}});return d}async function v(e,t={}){const{apiKey:n,customParameters:r,signal:o}=t,{data:s}=await(0,i.A)(e,{signal:o,headers:{accept:"application/json"},query:{...r,token:n}});return s.url=e,s}async function x(e,t={}){const{links:n,url:r}=e,o=O(n,"service-desc","application/vnd.oai.openapi+json;version=3.0");if(null==o)return w().warn("ogc-feature-layer:missing-openapi-page","The OGC API-Features server does not have an OpenAPI page."),null;const{apiKey:a,customParameters:l,signal:c}=t,u=(0,s.s2)(o.href,r),{data:f}=await(0,i.A)(u,{signal:c,headers:{accept:"application/vnd.oai.openapi+json;version=3.0"},query:{...l,token:a}});return f}function N(e){const t=/^http:\/\/www\.opengis.net\/def\/crs\/(?<authority>.*)\/(?<version>.*)\/(?<code>.*)$/i.exec(e),n=t?.groups;if(!n)return null;const{authority:i,code:r}=n;switch(i.toLowerCase()){case"ogc":switch(r.toLowerCase()){case"crs27":return a.A.GCS_NAD_1927.wkid;case"crs83":return 4269;case"crs84":case"crs84h":return a.A.WGS84.wkid;default:return null}case"esri":case"epsg":{const e=Number.parseInt(r,10);return Number.isNaN(e)?null:e}default:return null}}async function k(e,t,n){const i=await P(e,t,n);return(0,u.ZF)(i)}async function P(e,t,n){const{collection:{links:o,landingPage:{url:p}},layerDefinition:y,maxRecordCount:h,queryParameters:{apiKey:w,customParameters:b},spatialReference:I,supportedCrs:T}=e,F=O(o,"items","application/geo+json")||O(o,"http://www.opengis.net/def/rel/ogc/1.0/items","application/geo+json");if(!F)throw new r.A("ogc-feature-layer:missing-items-page","Missing items url");const{geometry:S,num:j,start:A,timeExtent:v,where:x}=t;if(t.objectIds)throw new r.A("ogc-feature-layer:query-by-objectids-not-supported","Queries with object ids are not supported");const N=a.A.fromJSON(I),k=t.outSpatialReference??N,P=k.isWGS84?null:C(k,T),M=$(S,T),G=function(e){if(!e)return null;const{start:t,end:n}=e;return`${null!=t?t.toISOString():".."}/${null!=n?n.toISOString():".."}`}(v),E=(H=x)&&"1=1"!==H?H:null,D=j??(null==A?h:10),R=0===A?void 0:A,{fields:q,geometryType:W,hasZ:Z,objectIdField:U,paginationParameter:L}=y,_=(0,s.s2)(F.href,p),{data:B}=await(0,i.A)(_,{...n,query:{...b,...M,crs:P,datetime:G,query:E,limit:D,[L]:R,token:w},headers:{accept:"application/geo+json"}}),J=(0,d.bd)(B,{geometryType:W,hasZ:Z,objectIdField:U}),K=J.length===D&&!!O(B.links??[],"next","application/geo+json"),V=new g.A(q);var H;for(const e of J){const t={};(0,m.MB)(V,t,e.attributes,!0);for(const e of V.fields)e.nullable&&!(e.name in t)&&(t[e.name]=null);t[U]=e.attributes[U],e.attributes=t}if(!P&&k.isWebMercator)for(const e of J)if(null!=e.geometry&&null!=W){const t=(0,u.zv)(e.geometry,W,Z,!1);t.spatialReference=a.A.WGS84,e.geometry=(0,u.Ux)((0,c.Cv)(t,k))}for(const e of J)e.objectId=e.attributes[U];const z=P||!P&&k.isWebMercator?k.toJSON():l.KK,Y=new f.A;return Y.exceededTransferLimit=K,Y.features=J,Y.fields=q,Y.geometryType=W,Y.hasZ=Z,Y.spatialReference=z,Y}function C(e,t){const{isWebMercator:n,wkid:i,latestWkid:r}=e;if(!i&&!r)return null;const o=n?t[3857]??t[102100]??t[102113]??t[900913]:i&&t[i]||r&&t[r];return o?`${T}${o}`:null}function M(e){if(!e)return"";const{xmin:t,ymin:n,xmax:i,ymax:r}=e;return`${t},${n},${i},${r}`}function $(e,t){if(!function(e){return null!=e&&"extent"===e.type}(e))return null;const{spatialReference:n}=e;if(!n||n.isWGS84)return{bbox:M(e)};const i=C(n,t);return null!=i?{bbox:M(e),"bbox-crs":i}:n.isWebMercator?{bbox:M((0,c.Cv)(e,a.A.WGS84))}:null}function G(e){const t=e.extent?.spatial;if(!t)return null;const n=t.bbox[0],i=4===n.length,[r,o]=n,s=i?void 0:n[2];return{xmin:r,ymin:o,xmax:i?n[2]:n[3],ymax:i?n[3]:n[4],zmin:s,zmax:i?void 0:n[5],spatialReference:a.A.WGS84.toJSON()}}function O(e,t,n){return e.find(({rel:e,type:i})=>e===t&&i===n)??e.find(({rel:e,type:n})=>e===t&&!n)}function E(e,t,n){if(!n)return;const i=O(n,"next","application/geo+json"),r=(0,s.An)(i?.href)?.query;if(!r)return;const o=(0,s.An)(e).query,a=Object.keys(o??{}),l=Object.entries(r).filter(([e])=>!a.includes(e)).find(([e,n])=>I.has(e.toLowerCase())&&Number.parseInt(n,10)===t),c=l?.[0];return c}},82832:(e,t,n)=>{n.d(t,{$1:()=>y,CR:()=>g,MB:()=>d,PC:()=>h,Yx:()=>l,bP:()=>u});var i=n(67482),r=n(21325),o=n(30524);class s{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 s(e)}}function l(e){return new a(e)}class c{constructor(e){this.globalId=null,this.success=!0,this.objectId=this.uniqueId=e}}function u(e){return new c(e)}const f=new Set;function d(e,t,n,i=!1){f.clear();for(const r in n){const s=e.get(r);if(!s)continue;const a=p(s,n[r]);if(f.add(s.name),s&&(i||s.editable)){const e=(0,o.CJ)(s,a);if(e)return l((0,o.uo)(e,s,a));t[s.name]=a}}for(const t of e.requiredFields??[])if(!f.has(t.name))return l(`missing required field "${t.name}"`);return null}function p(e,t){let n=t;return(0,o.WA)(e)&&"string"==typeof t?n=parseFloat(t):(0,o.yM)(e)&&null!=t&&"string"!=typeof t?n=String(t):(0,o.vE)(e)&&"string"==typeof t&&(n=(0,i._U)(t)),(0,o.WX)(n)}let m;function g(e,t){if(!e||!(0,r.fn)(t))return e;if("rings"in e||"paths"in e){if(null==m)throw new TypeError("geometry engine not loaded");return m.simplify(t,e)}return e}async function y(e,t){!(0,r.fn)(e)||"esriGeometryPolygon"!==t&&"esriGeometryPolyline"!==t||await async function(){return null==m&&(m=await Promise.all([n.e(3209),n.e(7559)]).then(n.bind(n,47559))),m}()}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:()=>A,bd:()=>v,sO:()=>j,xD:()=>f});var i=n(67482),r=n(49186),o=n(21325),s=n(90708),a=n(43334),l=n(92722),c=n(30524);const u={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function f(e){return u[e]}function*d(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*p(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 m(e){for(const t of e)if(t.length>2)return!0;return!1}function g(e){let t=0;for(let n=0;n<e.length;n++){const i=e[n],r=e[(n+1)%e.length];t+=i[0]*r[1]-r[0]*i[1]}return t<=0}function y(e){const t=e[0],n=e[e.length-1];t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t)}function h(e,t){const{coordinates:n,type:i}=e,r=t.hasZ??!1,o=!0;switch(i){case"Point":return new l.A([],[...n],r,!1);case"LineString":return(0,s.Ap)({paths:[n],hasZ:o},r,!1);case"MultiLineString":return(0,s.Ap)({paths:n,hasZ:o},r,!1);case"MultiPoint":return(0,s.PR)({points:n,hasZ:o},r,!1);case"Polygon":case"MultiPolygon":{const e=new l.A([],[],r,!1);for(const t of"Polygon"===i?[n]:n){w(e,t[0],r);for(let n=1;n<t.length;n++)b(e,t[n],r)}return e}}}function w(e,t,n){y(t),function(e){return!g(e)}(t)?T(e,t,n):I(e,t,n)}function b(e,t,n){y(t),function(e){return g(e)}(t)?T(e,t,n):I(e,t,n)}function I(e,t,n){for(const i of t)F(e,i,n);e.lengths.push(t.length)}function T(e,t,n){for(let i=t.length-1;i>=0;i--)F(e,t[i],n);e.lengths.push(t.length)}function F(e,[t,n,i],r){e.coords.push(t,n),r&&e.coords.push(i||0)}function S(e){switch(typeof e){case"string":return(0,i.Br)(e)?"esriFieldTypeDate":"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function j(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 i="string"==typeof n?n:"name"===n.type?n.properties.name:"EPSG"===n.type?n.properties.code:null,s=(0,o.oT)({wkid:t})?new RegExp(".*(CRS84H?|4326)$","i"):new RegExp(`.*(${t})$`,"i");if(!i||!s.test(i))throw new r.A("geojson:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:n})}function A(e,t={}){const n=[],i=new Set,r=new Set;let o,s=!1,a=null,l=!1,{geometryType:u=null}=t;for(const t of d(e)){const{geometry:e,properties:d,id:g}=t;if((!e||(u||(u=f(e.type)),f(e.type)===u))&&(s||(s=m(p(e))),l||(l=null!=g,l&&(o=typeof g,d&&(a=Object.keys(d).filter(e=>d[e]===g)))),d&&a&&l&&null!=g&&(a.length>1?a=a.filter(e=>d[e]===g):1===a.length&&(a=d[a[0]]===g?a:[])),d))for(const e in d){if(i.has(e))continue;const t=S(d[e]);if("unknown"===t){r.add(e);continue}r.delete(e),i.add(e);const o=(0,c.rS)(e);o&&n.push({name:o,alias:e,type:t})}}const g=(0,c.rS)(1===a?.length&&a[0]||null)??void 0;if(g)for(const e of n)if(e.name===g&&(0,c.WA)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:u,hasZ:s,objectIdFieldName:g,objectIdFieldType:o,unknownFields:Array.from(r)}}function v(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:i}=t;for(const r of e){const{geometry:e,properties:o,id:s}=r;if(e&&f(e.type)!==n)continue;const l=o||{};let c;i&&(c=l[i],null==s||c||(l[i]=c=s)),yield new a.Om(e&&h(e,t),l,null,c)}}(d(e),t))}}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3106],{159:(e,t,r)=>{r.d(t,{A:()=>u});var n,i=r(31635),s=r(69622),o=r(10107),l=(r(44208),r(53966),r(87811),r(64108)),a=r(99157);let u=n=class extends s.A{constructor(e){super(e),this.steps=[]}getInverse(){const e=new n;for(let t=this.steps.length-1;t>=0;t--){const r=this.steps[t];e.steps.push(r.getInverse())}return e}};(0,i.Cg)([(0,o.MZ)({type:[a.A],nonNullable:!0})],u.prototype,"steps",void 0),u=n=(0,i.Cg)([(0,l.$)("esri.geometry.operators.support.GeographicTransformation")],u)},6455:(e,t,r)=>{r.d(t,{FJ:()=>v,Dp:()=>w,KV:()=>C});var n=r(31635),i=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(64108)),l=r(89317),a=r(69540),u=r(7762),p=r(25482),c=r(43937),d=r(83960),y=r(13069);const f={write:{overridePolicy:(e,t,r)=>({enabled:!r||"scale"===r.filterMode})}};let h=class extends((0,a.OU)(p.o)){constructor(e){super(e),this.id=(0,y.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"id",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:f})],h.prototype,"maxScale",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:f})],h.prototype,"minScale",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"title",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"where",void 0),h=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilter")],h);var g=r(41560);let m=class extends((0,a.OU)(p.o)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(u.A.ofType(h)),this.mode="manual"}writeFilters(e,t,r,n){const i=e.toArray();"scale"===this.mode&&i.sort((e,t)=>{const r=(0,d.oW)(t.minScale,e.minScale),n=e.maxScale-t.maxScale;return 0===r?n:r}),t[r]=i.map(e=>e.toJSON(n))}write(e,t){return super.write(e,(0,g.mW)(this,t))}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:{overridePolicy:(e,t,r)=>({enabled:"manual"===r.filterMode,isRequired:!0})}}})],m.prototype,"activeFilterId",void 0),(0,n.Cg)([(0,s.MZ)({type:u.A.ofType(h),nonNullable:!0,json:{write:!0}})],m.prototype,"filters",void 0),(0,n.Cg)([(0,c.K)("filters")],m.prototype,"writeFilters",null),(0,n.Cg)([(0,s.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],m.prototype,"mode",void 0),m=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilterInfo")],m);const v=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,n.Cg)([(0,s.MZ)(w)],r.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,s.MZ)(C)],r.prototype,"displayFilterInfo",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.DisplayFilteredLayer")],r),r},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:l.K,writer(e,t,r){(0,i.sM)(r,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},C={type:m,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:l.K},origins:{"web-scene":{write:!1,read:!1}}}}},8303:(e,t,r)=>{r.d(t,{A:()=>I});var n=r(31635),i=r(92602),s=r(70333),o=r(11254),l=r(60999),a=r(49186),u=r(53966),p=r(97768),c=r(74887),d=r(84952),y=r(10107),f=(r(44208),r(87811),r(36005)),h=r(64108),g=r(43937),m=r(77548),v=r(20655),w=r(80812),C=r(41318),M=r(10407);const I=e=>{const t=e;let I=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new w.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:n}=await r.e(1204).then(r.bind(r,41204));return(0,c.Te)(t),await n({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!i.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:n},content:{updateItem:i}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",n),this._set("userHasUpdateItemPrivileges",i)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const n=!s.id?.findCredential(this.url),i=e===r.id;if(i&&r.portal.user)return this._getUserPrivileges(r,n);let o,l;if(i)o=r.portal.url;else try{o=await(0,m.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!o||!(0,d.b8)(o,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;l=await(s.id?.getCredential(`${o}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}const a=!0,u=!1,p=!1;if(!l)return{features:{edit:a,fullEdit:u},content:{updateItem:p}};try{if(i?await r.reload():(r=new w.default({id:e,portal:{url:o}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,n)}catch(e){(0,c.QP)(e)}return{features:{edit:a,fullEdit:u},content:{updateItem:p}}}_getUserPrivileges(e,t){const r=(0,M.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;const r=x.credential===t?x.user:await this._fetchEditingUser(e);return x.credential=t,x.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=s.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const n=`${r.owningSystemUrl}/sharing/rest`,i=v.A.getDefault();if(i&&i.loaded&&(0,d.S8)(i.restUrl)===(0,d.S8)(n))return i.user;const a=`${n}/community/self`,u=null!=e?e.signal:null,p=await(0,l.Ke)((0,o.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?C.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,n=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return r&&n&&!(0,d.ut)(n.restUrl,r.restUrl)?(t.messages&&t.messages.push(new a.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,n.Cg)([(0,y.MZ)({type:w.default})],I.prototype,"portalItem",null),(0,n.Cg)([(0,f.w)("web-document","portalItem",["itemId"])],I.prototype,"readPortalItem",null),(0,n.Cg)([(0,g.K)("web-document","portalItem",{itemId:{type:String}})],I.prototype,"writePortalItem",null),(0,n.Cg)([(0,y.MZ)({clonable:!1})],I.prototype,"resourceReferences",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasEditingPrivileges",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasFullEditingPrivileges",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasUpdateItemPrivileges",void 0),I=(0,n.Cg)([(0,h.$)("esri.layers.mixins.PortalLayer")],I),I},x={credential:null,user:null}},9762:(e,t,r)=>{r.r(t),r.d(t,{projectBuffer:()=>i});var n=r(37539);function i(e,t,r,i,s,o,l=Math.floor(e.length/3)){const a=(0,n.jd)(t,s);if(null==a)return!1;if(a===n.pO){if(e===i&&r===o)return!0;const t=r+3*l;for(let n=r,s=o;n<t;n++,s++)i[s]=e[n];return!0}const u=r+3*l;for(let t=r,n=o;t<u;t+=3,n+=3)a(e,t,i,n);return!0}},10184:(e,t,r)=>{r.d(t,{A:()=>c});var n=r(31635),i=r(69540),s=r(25482),o=r(88930),l=r(10107),a=(r(44208),r(53966),r(87811),r(93223)),u=r(64108),p=r(73133);let c=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,n.Cg)([(0,a.e)(p.j,{nonNullable:!0})],c.prototype,"unit",void 0),(0,n.Cg)([(0,l.MZ)({type:Number,json:{write:!0},nonNullable:!0})],c.prototype,"value",void 0),c=(0,n.Cg)([(0,u.$)("esri.time.TimeInterval")],c)},10407:(e,t,r)=>{r.d(t,{It:()=>y,LG:()=>o,OM:()=>u,Sm:()=>p,Y:()=>l,bK:()=>a,mm:()=>d,sQ:()=>c});var n=r(91218),i=r(16930),s=r(28735);function o(e,t){if(!l(e,t)){const r=e.typeKeywords;r?r.push(t):e.typeKeywords=[t]}}function l(e,t){return!!e.typeKeywords?.includes(t)}function a(e){return l(e,d.HOSTED_SERVICE)}function u(e,t){const r=e.typeKeywords;if(r){const e=r.indexOf(t);e>-1&&r.splice(e,1)}}function p(e,t,r){r?o(e,t):u(e,t)}async function c(e){const t=e.clone().normalize();let r;if(t.length>1)for(const e of t)r?e.width>r.width&&(r=e):r=e;else r=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,s.ci)(e);const r=i.A.WGS84;return await(0,n.initializeProjection)(t,r),(0,n.project)(e,r)}(r)}const d={CHARTS:"Charts",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function y(e){const{portal:t,isOrgItem:r,itemControl:n}=e,i=t.user?.privileges;let s=!i||i.includes("features:user:edit"),o=!!r&&!!i?.includes("features:user:fullEdit");const l="update"===n||"admin"===n;return l?o=s=!0:o&&(s=!0),{features:{edit:s,fullEdit:o},content:{updateItem:l}}}},17036:(e,t,r)=>{r.d(t,{p:()=>a});var n=r(44208),i=r(53966),s=r(20437),o=r(95466),l=r(30524);function a(){return{fields:{type:[s.A],value:null,set:function(e){if(e&&(0,n.A)("big-integer-warning-enabled")){const t=e.filter(e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8);if(t.length){const e=t.map(e=>`'${e.name}'`).join(", ");i.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return o.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||i.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,l.DB)(this.fieldsIndex,e)}}}}},22671:(e,t,r)=>{r.d(t,{A:()=>v});var n,i=r(31635),s=r(52106),o=r(66552),l=r(25482),a=r(4718),u=r(10107),p=(r(44208),r(53966),r(36005)),c=r(64108),d=r(43937),y=r(16930),f=r(65864),h=r(50498),g=r(20437);const m=new o.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let v=n=class extends l.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,s.A)}writeGeometryType(e,t,r,n){if(e)return void m.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void m.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,f.rS)(e);return n&&!r&&t.spatialReference&&(n.spatialReference=y.A.fromJSON(t.spatialReference)),n}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new n(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const n=t.features[r];if(n.geometry){const t=e?.[r];n.geometry=t?.toJSON()||n.geometry}}return t}quantize(e){const{scale:[t,r],translate:[n,i]}=e,s=this.features,o=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-n)/t),e=>Math.round((i-e)/r));for(let e=0,t=s.length;e<t;e++)o?.(s[e].geometry)||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[n,i],scale:[s,o]}=r;let l=null,a=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;l=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;a=r=>null==r?r:r*t+e}const u=this._getHydrationFunction(e,e=>e*s+n,e=>i-e*o,l,a);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){const n=y.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const s=e[t],o=r.fromJSON(s),l=s.geometry?.spatialReference;null==o.geometry||l||(o.geometry.spatialReference=n);const a=s.aggregateGeometries,u=o.aggregateGeometries;if(a&&null!=u)for(const e in u){const t=u[e],r=a[e],i=r?.spatialReference;null==t||i||(t.spatialReference=n)}i.push(o)}return i}_quantizePoints(e,t,r){let n,i;const s=[];for(let o=0,l=e.length;o<l;o++){const l=e[o];if(o>0){const e=t(l[0]),o=r(l[1]);e===n&&o===i||(s.push([e-n,o-i]),n=e,i=o)}else n=t(l[0]),i=r(l[1]),s.push([n,i])}return s.length>0?s:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const n=(0,f.Bi)(e)?e.rings:e.paths,i=[];for(let e=0,s=n.length;e<s;e++){const s=n[e],o=this._quantizePoints(s,t,r);o&&i.push(o)}return i.length>0?((0,f.Bi)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const n=this._quantizePoints(e.points,t,r);return n&&n.length>0?(e.points=n,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,n,i){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),n&&(e.z=n(e.z))}:"polyline"===e||"polygon"===e?e=>{const s=(0,f.Bi)(e)?e.rings:e.paths;let o,l;for(let e=0,n=s.length;e<n;e++){const n=s[e];for(let e=0,i=n.length;e<i;e++){const i=n[e];e>0?(o+=i[0],l+=i[1]):(o=i[0],l=i[1]),i[0]=t(o),i[1]=r(l)}}if(n&&i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=n(r[2]),r[3]=i(r[3])}}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=n(r[2])}}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),n&&null!=e.zmax&&null!=e.zmin&&(e.zmax=n(e.zmax),e.zmin=n(e.zmin)),i&&null!=e.mmax&&null!=e.mmin&&(e.mmax=i(e.mmax),e.mmin=i(e.mmin))}:"multipoint"===e?e=>{const s=e.points;let o,l;for(let e=0,n=s.length;e<n;e++){const n=s[e];e>0?(o+=n[0],l+=n[1]):(o=n[0],l=n[1]),n[0]=t(o),n[1]=r(l)}if(n&&i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=n(t[2]),t[3]=i(t[3])}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=n(t[2])}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2])}}:null}};(0,i.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],v.prototype,"displayFieldName",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"exceededTransferLimit",void 0),(0,i.Cg)([(0,u.MZ)({type:[s.A],json:{write:!0}})],v.prototype,"features",void 0),(0,i.Cg)([(0,p.w)("features")],v.prototype,"readFeatures",null),(0,i.Cg)([(0,u.MZ)({type:[g.A],json:{write:!0}})],v.prototype,"fields",void 0),(0,i.Cg)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:m.read}}})],v.prototype,"geometryType",void 0),(0,i.Cg)([(0,d.K)("geometryType")],v.prototype,"writeGeometryType",null),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasM",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasZ",void 0),(0,i.Cg)([(0,u.MZ)({types:h.yR,json:{write:!0}})],v.prototype,"queryGeometry",void 0),(0,i.Cg)([(0,p.w)("queryGeometry")],v.prototype,"readQueryGeometry",null),(0,i.Cg)([(0,u.MZ)({type:y.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),(0,i.Cg)([(0,d.K)("spatialReference")],v.prototype,"writeSpatialReference",null),(0,i.Cg)([(0,u.MZ)({json:{write:!0}})],v.prototype,"transform",void 0),v=n=(0,i.Cg)([(0,c.$)("esri.rest.support.FeatureSet")],v),v.prototype.toJSON.isDefaultToJSON=!0},29005:(e,t,r)=>{r.d(t,{A:()=>p});var n=r(31635),i=r(69540),s=r(66552),o=r(25482),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let p=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"name",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"description",void 0),(0,n.Cg)([(0,l.MZ)({json:{read:u.read,write:u.write}})],p.prototype,"drawingTool",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"prototype",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"thumbnail",void 0),p=(0,n.Cg)([(0,a.$)("esri.layers.support.FeatureTemplate")],p)},32756:(e,t,r)=>{r.d(t,{Rr:()=>a,fY:()=>p,ne:()=>u});var n=r(31635),i=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(64108)),l=r(91880);function a(e,t,r){if(!e)return null;const n=e.find(e=>!!e.field);if(!n)return null;const i=new l.A;return i.read(n,r),[i]}const u={type:[l.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:a},write:{writer:function(e,t,r,n){const s=e.find(e=>!!e.field);s&&(0,i.sM)(r,[s.toJSON()],t)}}}},p=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,n.Cg)([(0,s.MZ)(u)],r.prototype,"orderBy",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.OrderedLayer")],r),r}},33143:(e,t,r)=>{r.d(t,{A:()=>d});var n=r(31635),i=r(69540),s=r(25482),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(64108),u=r(43937),p=r(80451),c=r(29005);let d=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,p.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"id",void 0),(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"name",void 0),(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"domains",void 0),(0,n.Cg)([(0,l.w)("domains")],d.prototype,"readDomains",null),(0,n.Cg)([(0,u.K)("domains")],d.prototype,"writeDomains",null),(0,n.Cg)([(0,o.MZ)({type:[c.A],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,n.Cg)([(0,a.$)("esri.layers.support.FeatureType")],d)},37539:(e,t,r)=>{r.d(t,{pO:()=>h,jd:()=>d,Tp:()=>y,w5:()=>c});var n=r(34727),i=r(83047),s=r(73941),o=r(79258);Math.PI;const l=o.$O.radius,a=o.$O.eccentricitySquared,u={a1:l*a,a2:l*a*l*a,a3:l*a*a/2,a4:l*a*l*a*2.5,a5:l*a+l*a*a/2,a6:1-a};o.$O.radius,o.$O.flattening,o.Sw.radius,o.Sw.flattening,o.sH.radius,o.sH.flattening,o.sH.radius;var p=r(21325);const c={2:{5:h,7:null,9:null,10:h,1:x,6:null,8:null,0:null,3:m,11:v,2:h,4:O},5:{5:h,7:null,9:null,10:h,1:x,6:null,8:null,0:null,3:m,11:v,2:h,4:O},7:{5:null,7:h,9:null,10:h,1:null,6:I,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:h,10:h,1:null,6:null,8:M,0:null,3:null,11:null,2:null,4:null},3:{5:g,7:null,9:null,10:g,1:function(e,t,r,n){const i=e[t]/E,s=j-2*Math.atan(Math.exp(-e[t+1]/E)),o=E+e[t+2],l=Math.cos(s)*o;r[n]=Math.cos(i)*l,r[n+1]=Math.sin(i)*l,r[n+2]=Math.sin(s)*o},6:null,8:null,0:null,3:h,11:function(e,t,r,n){g(e,t,r,n),v(r,n,r,n)},2:g,4:function(e,t,r,n){g(e,t,r,n),O(r,n,r,n)}},4:{5:P,7:null,9:null,10:P,1:function(e,t,r,n){P(e,t,r,n),x(r,n,r,n)},6:null,8:null,0:null,3:function(e,t,r,n){P(e,t,r,n),m(r,n,r,n)},11:function(e,t,r,n){P(e,t,r,n),v(r,n,r,n)},2:P,4:h},1:{5:R,7:null,9:null,10:R,1:h,6:null,8:null,0:null,3:function(e,t,r,n){R(e,t,r,n),m(r,n,r,n)},11:function(e,t,r,n){R(e,t,r,n),v(r,n,r,n)},2:R,4:function(e,t,r,n){R(e,t,r,n),O(r,n,r,n)}},6:{5:null,7:T,9:null,10:T,1:null,6:h,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:A,10:A,1:null,6:null,8:h,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:h,3:null,11:null,2:null,4:null},10:{5:h,7:h,9:h,10:h,1:x,6:I,8:M,0:null,3:m,11:v,2:h,4:O},11:{5:w,7:null,9:null,10:w,1:function(e,t,r,n){w(e,t,r,n),x(r,n,r,n)},6:null,8:null,0:null,3:function(e,t,r,n){w(e,t,r,n),m(r,n,r,n)},11:h,2:w,4:function(e,t,r,n){w(e,t,r,n),O(r,n,r,n)}}};function d(e,t){return y(e,t)?.projector}function y(e,t){if(null==e||null==t)return null;if(F.source.spatialReference===e&&F.dest.spatialReference===t)return F;const r=f(e,F.source),n=f(t,F.dest);return 0===r&&0===n?(0,p.aI)(e,t)?F.projector=h:F.projector=null:F.projector=c[r][n],F}function f(e,t){return e?t.spatialReference===e?t.spatialReferenceId:(t.spatialReference=e,"metersPerUnit"in t&&(t.metersPerUnit=(0,i.GA)(e,1)),(0,s.jA)(e)?t.spatialReferenceId=1:(0,p.oT)(e)?t.spatialReferenceId=2:(0,p.K8)(e)?t.spatialReferenceId=3:(0,p.r1)(e)?t.spatialReferenceId=11:e.wkt===s.Ro.wkt?t.spatialReferenceId=4:4490===e.wkid?t.spatialReferenceId=5:e.wkt===s.FY.wkt?t.spatialReferenceId=6:e.wkt===s.LJ.wkt?t.spatialReferenceId=8:(0,p.q8)(e)?t.spatialReferenceId=7:(0,p.KQ)(e)?t.spatialReferenceId=9:t.spatialReferenceId=0):0}function h(e,t,r,n){e!==r&&(r[n++]=e[t++],r[n++]=e[t++],r[n]=e[t])}function g(e,t,r,n){r[n]=Z*(e[t]/E),r[n+1]=Z*(j-2*Math.atan(Math.exp(-e[t+1]/E))),r[n+2]=e[t+2]}function m(e,t,r,i){!function(e,t,r,i,s){const o=.4999999*Math.PI,l=(0,n.qE)(b*e[t+1],-o,o),a=Math.sin(l);r[i++]=b*e[t]*s.radius,r[i++]=s.halfSemiMajorAxis*Math.log((1+a)/(1-a)),r[i]=e[t+2]}(e,t,r,i,o.$O)}function v(e,t,r,n){r[n]=e[t]*D,r[n+1]=e[t+1]*D,r[n+2]=e[t+2]}function w(e,t,r,n){r[n]=e[t]*U,r[n+1]=e[t+1]*U,r[n+2]=e[t+2]}function C(e,t,r,n,i){const s=i+e[t+2],o=b*e[t+1],l=b*e[t],a=Math.cos(o)*s;r[n]=Math.cos(l)*a,r[n+1]=Math.sin(l)*a,r[n+2]=Math.sin(o)*s}function M(e,t,r,n){C(e,t,r,n,o.Sw.radius)}function I(e,t,r,n){C(e,t,r,n,o.sH.radius)}function x(e,t,r,n){C(e,t,r,n,o.$O.radius)}function S(e,t,r,i,s){const o=e[t],l=e[t+1],a=e[t+2],u=Math.sqrt(o*o+l*l+a*a),p=(0,n.YN)(a/(0===u?1:u)),c=Math.atan2(l,o);r[i++]=Z*c,r[i++]=Z*p,r[i]=u-s}function A(e,t,r,n){S(e,t,r,n,o.Sw.radius)}function T(e,t,r,n){S(e,t,r,n,o.sH.radius)}function R(e,t,r,n){S(e,t,r,n,o.$O.radius)}function O(e,t,r,n){!function(e,t,r,n,i){const s=b*e[t],o=b*e[t+1],l=e[t+2],a=Math.sin(o),u=Math.cos(o),p=i.radius/Math.sqrt(1-i.eccentricitySquared*a*a);r[n++]=(p+l)*u*Math.cos(s),r[n++]=(p+l)*u*Math.sin(s),r[n++]=(p*(1-i.eccentricitySquared)+l)*a}(e,t,r,n,o.$O)}function P(e,t,r,n){const i=u,s=e[t],l=e[t+1],a=e[t+2];let p,c,d,y,f,h,g,m,v,w,C,M,I,x,S,A,T,R,O,P,F;p=Math.abs(a),c=s*s+l*l,d=Math.sqrt(c),y=c+a*a,f=Math.sqrt(y),P=Math.atan2(l,s),h=a*a/y,g=c/y,x=i.a2/f,S=i.a3-i.a4/f,g>.3?(m=p/f*(1+g*(i.a1+x+h*S)/f),O=Math.asin(m),w=m*m,v=Math.sqrt(1-w)):(v=d/f*(1-h*(i.a5-x-g*S)/f),O=Math.acos(v),w=1-v*v,m=Math.sqrt(w)),C=1-o.$O.eccentricitySquared*w,M=o.$O.radius/Math.sqrt(C),I=i.a6*M,x=d-M*v,S=p-I*m,T=v*x+m*S,A=v*S-m*x,R=A/(I/C+T),O+=R,F=T+A*R/2,a<0&&(O=-O),r[n++]=Z*P,r[n++]=Z*O,r[n]=F}const F={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:h},b=(0,n.kU)(1),Z=(0,n.KJ)(1),j=.5*Math.PI,E=o.$O.radius,D=E*Math.PI/180,U=180/(E*Math.PI)},52136:(e,t,r)=>{r.d(t,{p:()=>o});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108));const o=e=>{const t=e;let r=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,n.Cg)([(0,i.MZ)({type:String})],r.prototype,"apiKey",null),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.APIKeyMixin")],r),r}},62815:(e,t,r)=>{r.d(t,{N:()=>o});var n=r(83047),i=r(73941),s=r(21325);function o(e,t,r){if(null==t||null==r||r.vcsWkid||(0,s.aI)(t,r)||(0,i.xP)(t)||(0,i.xP)(r))return null;const o=(0,n.G9)(t)/(0,n.G9)(r);if(1===o)return null;switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,o);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e)for(const r of e.paths)for(const e of r)e.length>2&&(e[2]*=t)}(e,o);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e)for(const r of e.rings)for(const e of r)e.length>2&&(e[2]*=t)}(e,o);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const r of e.points)r.length>2&&(r[2]*=t)}(e,o);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,o);default:return null}}},63396:(e,t,r)=>{r.d(t,{d:()=>x});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108)),o=r(60950),l=r(99959);class a extends l.A{constructor(e){super(),this.type="track",this.trackInfoProvider=e}get id(){return this.trackInfoProvider.id}get[o.ym](){return this.trackInfoProvider.trackInfo}}var u=r(37838),p=r(69540),c=r(25482),d=r(93637),y=r(43937),f=r(50820),h=r(10873),g=r(46499),m=r(41214);let v=class extends((0,p.OU)(c.o)){constructor(e){super(e),this.labelingInfo=null,this.labelsVisible=!0,this.renderer=null,this.visible=!0}};(0,n.Cg)([(0,i.MZ)({type:[g.A],json:{write:!0}})],v.prototype,"labelingInfo",void 0),(0,n.Cg)([(0,i.MZ)(h.kF)],v.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,i.MZ)({types:m.Hg,json:{write:!0}})],v.prototype,"renderer",void 0),(0,n.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],v.prototype,"visible",void 0),v=(0,n.Cg)([(0,s.$)("esri.layers.support.TrackPartInfo")],v);var w=r(96576),C=r(59868),M=r(10184);let I=class extends((0,p.OU)(c.o)){constructor(e){super(e),this.enabled=!0,this.fields=[],this.latestObservations=new v({renderer:new w.A({symbol:C.UK.clone()})}),this.maxDisplayDuration=null,this.maxDisplayObservationsPerTrack=0,this.popupEnabled=!0,this.popupTemplate=null,this.previousObservations=new v({renderer:new w.A({symbol:C.UK.clone()})}),this.trackLines=new v({renderer:new w.A({symbol:C.A7.clone()})}),this.timeField="startTimeField"}writeFields(e,t,r){const n=e.filter(e=>"avg_angle"!==e.statisticType).map(e=>e.toJSON());(0,d.sM)(r,n,t)}};(0,n.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],I.prototype,"enabled",void 0),(0,n.Cg)([(0,i.MZ)({type:[f.A],json:{write:!0}})],I.prototype,"fields",void 0),(0,n.Cg)([(0,y.K)("fields")],I.prototype,"writeFields",null),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"latestObservations",void 0),(0,n.Cg)([(0,i.MZ)({type:M.A,json:{write:!0}})],I.prototype,"maxDisplayDuration",void 0),(0,n.Cg)([(0,i.MZ)({type:Number,json:{write:!0}})],I.prototype,"maxDisplayObservationsPerTrack",void 0),(0,n.Cg)([(0,i.MZ)(h.M6)],I.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,i.MZ)({type:u.A,json:{name:"popupInfo",write:!0}})],I.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"previousObservations",void 0),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"trackLines",void 0),(0,n.Cg)([(0,i.MZ)({type:["timeReceived","startTimeField","endTimeField"],json:{read:!0,write:!0}})],I.prototype,"timeField",void 0),I=(0,n.Cg)([(0,s.$)("esri.layers.support.TrackInfo")],I);const x=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.trackGraphicOrigin=new a(this),this.trackInfo=null}};return(0,n.Cg)([(0,i.MZ)({readOnly:!0,clonable:!1})],r.prototype,"trackGraphicOrigin",void 0),(0,n.Cg)([(0,i.MZ)({type:I})],r.prototype,"trackInfo",void 0),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.TrackableLayer")],r),r}},64714:(e,t,r)=>{r.d(t,{F0:()=>l,Vx:()=>p,e2:()=>d,f:()=>y});var n=r(44208),i=r(4718),s=r(99352),o=r(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 p(e,t){if((0,n.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let r=`this${c(t)} = null;`;for(const t in e)r+=`this${c(t)} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new n}catch(r){return()=>({[t]:null,...e})}}function c(e){return a.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,i.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,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},65977:(e,t,r)=>{r.r(t),r.d(t,{default:()=>V});var n=r(31635),i=r(37838),s=r(49186),o=r(25728),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108)),u=r(5443),p=r(16930),c=r(50498),d=r(55156),y=r(60950),f=r(89808),h=r(99959);const g=Symbol("isOGCFeatureGraphicOrigin");var m;class v extends h.A{get[(m=g,y.ym)](){return this.layer}get[d.e](){return this.layer}get[f.Q](){return this.layer}constructor(e){super(),this[m]=!0,this.type="ogc-feature",this.layer=e}get id(){return this.layer.id}}var w=r(4146),C=r(92474),M=r(799),I=r(75321),x=r(4071),S=r(22671);let A=class extends C.x_{constructor(){super(...arguments),this.featureDefinition=null,this.type="ogc-feature"}load(e){return this.addResolvingPromise(this._loadOGCServices(this.layer,e)),this.when()}getSource(){const{featureDefinition:{collection:e,layerDefinition:t,spatialReference:r,supportedCrs:n},layer:{apiKey:i,customParameters:s,effectiveMaxRecordCount:o}}=this;return{type:"ogc-source",collection:e,layerDefinition:t,maxRecordCount:o,queryParameters:{apiKey:i,customParameters:s},spatialReference:r,supportedCrs:n}}queryExtent(e,t={}){return null}queryFeatureCount(e,t={}){return null}queryFeatures(e,t={}){return this.queryFeaturesJSON(e,t).then(e=>S.A.fromJSON(e))}queryFeaturesJSON(e,t={}){const r=this.getSource();return this.load(t).then(()=>(0,I.bW)(r,e,t))}queryObjectIds(e,t={}){return null}serviceSupportsSpatialReference(e){const{isWebMercator:t,isWGS84:r,latestWkid:n,wkid:i}=e,{supportedCrs:s}=this.featureDefinition;return r||t||!!i&&!!s[i]||!!n&&!!s[n]}_conformsToType(e,t){const r=new RegExp(`^${(0,M.Cj)(t)}$`,"i");return e.conformsTo.some(e=>r.test(e))??!1}_getCapabilities(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:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:{maxRecordCount:t,maxRecordCountFactor:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,supportsCacheHint:!1,supportsCentroid:!1,supportsCentroidOnDegeneratedQuantizedGeometry:!1,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPaginationOnAggregatedQueries:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsStatistics:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,supportsSqlExpression:!1,supportsTrueCurve:!1,tileMaxRecordCount:void 0},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:x.$,editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUploadWithItemId:!1,supportsUpdateWithoutM:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}_getMaxRecordCount(e){const t=e?.components?.parameters;return t?.limit?.schema?.maximum??t?.limitFeatures?.schema?.maximum}_getStorageSpatialReference(e){const t=e.storageCrs??I.QE,r=(0,I.J0)(t);return null==r?p.A.WGS84:new p.A({wkid:r})}_getSupportedSpatialReferences(e,t){const r="#/crs",n=e.crs??[I.QE],i=n.includes(r)?n.filter(e=>e!==r).concat(t.crs??[]):n,s=/^http:\/\/www\.opengis.net\/def\/crs\/epsg\/.*\/3785$/i;return i.filter(e=>!s.test(e))}async _loadOGCServices(e,t){const r=null!=t?t.signal:null,{apiKey:n,collectionId:i,customParameters:o,fields:l,geometryType:a,hasZ:u,objectIdField:p,timeInfo:d,url:y}=e,f={fields:l?.map(e=>e.toJSON()),geometryType:c.Ye.toJSON(a),hasZ:u??!1,objectIdField:p,timeInfo:d?.toJSON()},h={apiKey:n,customParameters:o,signal:r},g=await(0,I.Ki)(y,h),[m,v]=await Promise.all([(0,I.Px)(g,h),(0,I.bV)(g,h)]);if(!this._conformsToType(m,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/geojson"))throw new s.A("ogc-feature-layer:no-geojson-support","Server does not support geojson");const w=v.collections.find(({id:e})=>e===i);if(!w)throw new s.A("ogc-feature-layer:collection-not-found","Server does not contain the named collection");const C=this._conformsToType(m,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/oas30")?await(0,I.GA)(g,h):null,x=await(0,I.GL)(w,f,h),S=this._getMaxRecordCount(C),A=this._getCapabilities(x.hasZ,S),T=this._getStorageSpatialReference(w).toJSON(),R=this._getSupportedSpatialReferences(w,v),O=new RegExp(`^${(0,M.Cj)(I.vJ)}`,"i"),P={};for(const e of R){const t=(0,I.J0)(e);null!=t&&(P[t]||(P[t]=e.replace(O,"")))}this.featureDefinition={capabilities:A,collection:w,layerDefinition:x,spatialReference:T,supportedCrs:P}}};(0,n.Cg)([(0,l.MZ)()],A.prototype,"featureDefinition",void 0),(0,n.Cg)([(0,l.MZ)({constructOnly:!0})],A.prototype,"layer",void 0),(0,n.Cg)([(0,l.MZ)()],A.prototype,"type",void 0),A=(0,n.Cg)([(0,a.$)("esri.layers.graphics.sources.OGCFeatureSource")],A);var T=r(52136),R=r(63074),O=r(69208),P=r(6455),F=r(87718),b=r(56658),Z=r(16131),j=r(32756),E=r(8303),D=r(54310),U=r(25036),G=r(82935),_=r(63396),L=r(10873),N=r(33143),k=r(20437),B=r(17036),$=r(30524),z=r(46499),q=r(39383),Q=r(41214),H=r(61956),J=r(30291);const K=(0,B.p)();let W=class extends((0,P.FJ)((0,T.p)((0,O.d)((0,b.J)((0,F.F)((0,R.dM)((0,j.fY)((0,G.e)((0,_.d)((0,U.j)((0,Z.q)((0,E.A)((0,D.J)((0,o.P)(w.A))))))))))))))){constructor(e){super(e),this.capabilities=null,this.collectionId=null,this.copyright=null,this.description=null,this.displayField=null,this.elevationInfo=null,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,this.graphicOrigin=new v(this),this.hasZ=void 0,this.labelingInfo=null,this.labelsVisible=!0,this.legendEnabled=!0,this.maxRecordCount=null,this.objectIdField=null,this.operationalLayerType="OGCFeatureLayer",this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.source=new A({layer:this}),this.spatialReference=null,this.title=null,this.type="ogc-feature",this.typeIdField=null,this.types=null,this.url=null}destroy(){this.source?.destroy()}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["OGCFeatureServer"]},e).then(()=>this._fetchService(e))),this.when()}get defaultPopupTemplate(){return this.createPopupTemplate()}get effectiveMaxRecordCount(){return this.maxRecordCount??this.capabilities?.query.maxRecordCount??5e3}get isTable(){return this.loaded&&null==this.geometryType}set renderer(e){(0,$.yp)(e,this.fieldsIndex),this._set("renderer",e)}createPopupTemplate(e){return(0,J.tn)(this,e)}createQuery(){return new H.A}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){let r,n=!1;const i=t?.feature?.attributes,s=this.typeIdField&&i?.[this.typeIdField];return null!=s&&this.types&&(n=this.types.some(t=>t.id==s&&(r=t.domains?.[e],"inherited"===r?.type&&(r=this._getLayerDomain(e)),!0))),n||r||(r=this._getLayerDomain(e)),r}queryFeatures(e,t){return this.load().then(()=>this.source.queryFeatures(H.A.from(e)||this.createQuery(),t)).then(e=>(e?.features?.forEach(e=>{e.layer=e.sourceLayer=this,e.origin=this.graphicOrigin}),e))}async queryAttributeBins(e,t){throw new s.A("OGCFeatureLayer","Layer source does not support queryAttributeBins capability")}serviceSupportsSpatialReference(e){return this.source?.serviceSupportsSpatialReference(e)??!1}async _fetchService(e){await this.source.load(e),this.read(this.source.featureDefinition,{origin:"service"}),(0,$.yp)(this.renderer,this.fieldsIndex),(0,$.sv)(this.timeInfo,this.fieldsIndex)}_getLayerDomain(e){if(!this.fields)return null;for(const t of this.fields)if(t.name===e&&t.domain)return t.domain;return null}};(0,n.Cg)([(0,l.MZ)({readOnly:!0,json:{origins:{service:{read:!0}}}})],W.prototype,"capabilities",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],W.prototype,"collectionId",void 0),(0,n.Cg)([(0,l.MZ)({type:String})],W.prototype,"copyright",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0})],W.prototype,"defaultPopupTemplate",null),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:String,json:{origins:{service:{name:"collection.description"}}}})],W.prototype,"description",void 0),(0,n.Cg)([(0,l.MZ)({type:String})],W.prototype,"displayField",void 0),(0,n.Cg)([(0,l.MZ)({type:Number})],W.prototype,"effectiveMaxRecordCount",null),(0,n.Cg)([(0,l.MZ)(L.Yj)],W.prototype,"elevationInfo",void 0),(0,n.Cg)([(0,l.MZ)({type:[k.A],json:{origins:{service:{name:"layerDefinition.fields"}}}})],W.prototype,"fields",void 0),(0,n.Cg)([(0,l.MZ)(K.fieldsIndex)],W.prototype,"fieldsIndex",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:u.A,json:{origins:{service:{name:"layerDefinition.extent"}}}})],W.prototype,"fullExtent",void 0),(0,n.Cg)([(0,l.MZ)({type:c.gy.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:c.gy.read}}}}})],W.prototype,"geometryType",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,clonable:!1})],W.prototype,"graphicOrigin",void 0),(0,n.Cg)([(0,l.MZ)({type:Boolean,json:{origins:{service:{name:"layerDefinition.hasZ"}}}})],W.prototype,"hasZ",void 0),(0,n.Cg)([(0,l.MZ)({type:Boolean,readOnly:!0})],W.prototype,"isTable",null),(0,n.Cg)([(0,l.MZ)({type:[z.A],json:{origins:{"web-document":{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:q.w},write:!0}}}})],W.prototype,"labelingInfo",void 0),(0,n.Cg)([(0,l.MZ)(L.kF)],W.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,l.MZ)(L.fV)],W.prototype,"legendEnabled",void 0),(0,n.Cg)([(0,l.MZ)({type:Number})],W.prototype,"maxRecordCount",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{origins:{service:{name:"layerDefinition.objectIdField"}}}})],W.prototype,"objectIdField",void 0),(0,n.Cg)([(0,l.MZ)({type:["OGCFeatureLayer"]})],W.prototype,"operationalLayerType",void 0),(0,n.Cg)([(0,l.MZ)(L.M6)],W.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,l.MZ)({type:i.A,json:{name:"popupInfo",write:!0}})],W.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,l.MZ)({types:Q.Hg,json:{origins:{service:{name:"layerDefinition.drawingInfo.renderer",write:!1},"web-scene":{types:Q.XJ,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:!0}})],W.prototype,"renderer",null),(0,n.Cg)([(0,l.MZ)(L.PY)],W.prototype,"screenSizePerspectiveEnabled",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0})],W.prototype,"source",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:p.A,json:{origins:{service:{read:!0}}}})],W.prototype,"spatialReference",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{write:{enabled:!0,ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"collection.title"}}}})],W.prototype,"title",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,json:{read:!1}})],W.prototype,"type",void 0),(0,n.Cg)([(0,l.MZ)({type:String,readOnly:!0})],W.prototype,"typeIdField",void 0),(0,n.Cg)([(0,l.MZ)({type:[N.A]})],W.prototype,"types",void 0),(0,n.Cg)([(0,l.MZ)(L.OZ)],W.prototype,"url",void 0),W=(0,n.Cg)([(0,a.$)("esri.layers.OGCFeatureLayer")],W);const V=W},69208:(e,t,r)=>{r.d(t,{d:()=>o});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108));const o=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,n.Cg)([(0,i.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],r.prototype,"customParameters",void 0),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.CustomParametersMixin")],r),r}},73133:(e,t,r)=>{r.d(t,{j:()=>n});const n=(0,r(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},82935:(e,t,r)=>{r.d(t,{B:()=>y,e:()=>f});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(36005)),o=r(64108),l=r(89317),a=r(30524),u=r(96184),p=r(73133),c=r(79677),d=r(10184);const y={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:l.K}}},f=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const n=r.timeOffset,i=p.j.fromJSON(r.timeOffsetUnits);return n&&i?new d.A({value:n,unit:i}):null}set timeInfo(e){(0,a.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n.Cg)([(0,i.MZ)({type:c.A,json:{write:!1}})],r.prototype,"timeExtent",void 0),(0,n.Cg)([(0,i.MZ)({type:d.A})],r.prototype,"timeOffset",void 0),(0,n.Cg)([(0,s.w)("service","timeOffset",["timeInfo.exportOptions"])],r.prototype,"readOffset",null),(0,n.Cg)([(0,i.MZ)({value:null,type:u.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],r.prototype,"timeInfo",null),(0,n.Cg)([(0,i.MZ)(y)],r.prototype,"useViewTime",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.TemporalLayer")],r),r}},83960:(e,t,r)=>{r.d(t,{X_:()=>o,oW:()=>a,zx:()=>l});var n=r(34727),i=r(83047);const s=96;function o(e,t){const r=t||e.extent,n=e.width,o=(0,i.GA)(r?.spatialReference);return r&&n?r.width/n*o*i.dy*s:0}function l(e,t,r){return function(e,t){return 0===t||(0,n.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,n.Sp)(e,t)||e>t}(e,r)}function a(e,t){return(0,n.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},91218:(e,t,r)=>{r.r(t),r.d(t,{canProjectWithoutEngine:()=>z,initializeProjection:()=>Q,isEqualBaseGCS:()=>q,isLoaded:()=>F,isLoadedOrLoad:()=>b,isLoadedOrLoadFor:()=>Z,load:()=>E,project:()=>D,projectExtent:()=>re,projectMany:()=>U,projectMultipoint:()=>W,projectOrLoad:()=>G,projectOrLoadMany:()=>_,projectPoint:()=>J,projectPolygon:()=>ee,projectPolyline:()=>Y,projectWithZConversion:()=>$,projectWithoutEngine:()=>H,requiresLoad:()=>j,test:()=>k,tryProjectWithZConversion:()=>B,unload:()=>N});var n=r(49186),i=r(74887),s=r(62788),o=r(95488),l=r(51850),a=r(21276),u=r(73941),p=r(5443),c=r(91075),d=r(48526),y=r(86738),f=r(39829),h=r(82799),g=r(16930),m=r(159),v=r(9762),w=r(37539);function C(e,t,r,n,i,s){return M[0]=e,M[1]=t,M[2]=r,(0,v.projectBuffer)(M,n,0,i,s,0)}const M=(0,l.vt)();var I=r(21325),x=r(62815);let S=null,A=null,T=null,R=null,O={};const P=new o.I;function F(){return!!(A?.isLoaded()&&T?.isLoaded()&&R?.isLoaded())}function b(){return!!F()||((0,s.gc)(P),E(),!1)}function Z(e,t){return!e||!t||z(e,t)||b()}function j(e,t){return!z(e,t)&&!F()}async function E(e){null==S&&(S=Promise.all([r.e(3276).then(r.bind(r,83276)).then(e=>(A=e,A.load())),r.e(8377).then(r.bind(r,8377)).then(e=>(T=e,T.load())),r.e(2158).then(r.bind(r,12158)).then(e=>(R=e,R.load()))])),await S,(0,i.Te)(e),P.notify()}function D(e,t,r){return Array.isArray(e)?0===e.length?[]:((0,a.H)(e),U(e,e[0].spatialReference,t,r)):((0,a.f)(e),U([e],e.spatialReference,t,r)[0])}function U(e,t,r,n){if(null==t||null==r)return e;if(z(t,r,n))return e.map(e=>H(e,t,r));if(null==n?.geographicTransformation&&(0,u.jA)(t))return e.map(e=>H(e,t,g.A.WGS84)).map(e=>B(e,r));if(null==n?.geographicTransformation&&(0,u.jA)(r))return e.map(e=>B(e,g.A.WGS84)).map(e=>H(e,g.A.WGS84,r));if(!F())throw new L;if(!n?.geographicTransformation)if(n?.extendedParams)n={...n,geographicTransformation:R.getTransformation(t,r,n.areaOfInterestExtent)||new m.A};else if(!n?.areaOfInterestExtent){const e=function(e,t){return[e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??"",t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??""].join()}(t,r);let i=O[e];i||(i=R.getTransformation(t,r)||new m.A,O[e]=i),n={geographicTransformation:i}}return e[0].spatialReference||(e[0].spatialReference=t),e[0]instanceof c.A?A.executeMany(e,r,n):T.executeMany(e,r,n)}function G(e,t){const r=_([e],t);return null!=r.pending?{pending:r.pending,geometry:null}:null!=r.geometries?{pending:null,geometry:r.geometries[0]}:{pending:null,geometry:null}}function _(e,t){if(!F())for(const r of e)if(null!=r&&!(0,I.aI)(r.spatialReference,t)&&(0,I.fn)(r.spatialReference)&&(0,I.fn)(t)&&!z(r.spatialReference,t))return(0,s.gc)(P),{pending:E(),geometries:null};return{pending:null,geometries:e.map(e=>null==e?null:(0,I.aI)(e.spatialReference,t)?e:(0,I.fn)(e.spatialReference)&&(0,I.fn)(t)?B(e,t):null)}}class L extends n.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function N(){S=null,A=null,T=null,R=null,O={}}const k={get loadPromise(){return S}};function B(e,t){try{const r=D(e,t);if(null==r)return null;"xmin"in e&&"xmin"in r&&(r.zmin=e.zmin,r.zmax=e.zmax);const n=(0,x.N)(r.type,e.spatialReference,t);return null!=n&&n(r),r}catch(e){if(!(e instanceof L))throw e;return null}}async function $(e,t,r){const n=e.spatialReference;return null!=n&&null!=t&&await Q(n,t,null,r),B(e,t)}function z(e,t,r){return!(r?.areaOfInterestExtent||r?.extendedParams||r?.geographicTransformation)&&(!!(0,I.aI)(e,t)||(0,I.fn)(e)&&(0,I.fn)(t)&&!!(0,w.jd)(e,t))}function q(e,t){if((0,I.aI)(e,t))return!0;if(!(0,I.fn)(e)||!(0,I.fn)(t))return!1;const r=(0,I.oT)(e)||(0,I.K8)(e)||(0,I.x1)(e),n=(0,I.oT)(t)||(0,I.K8)(t)||(0,I.x1)(t);return r&&n}async function Q(e,t,r,n){if(F())return(0,i.NO)(n);if(Array.isArray(e)){for(const{source:t,dest:r,options:i}of e)if(t&&r&&!z(t,r,i))return E(n)}else if(e&&t&&!z(e,t,r))return E(n);return(0,i.NO)(n)}function H(e,t,r){return e?"x"in e?K(e,t,new y.A,r,0):"xmin"in e?ne(e,t,new p.A,r,0):"rings"in e?te(e,t,new f.A,r,0):"paths"in e?X(e,t,new h.A,r,0):"points"in e?V(e,t,new d.A,r,0):null:null}function J(e,t,r=t.spatialReference,n=0){return null!=r&&null!=e.spatialReference&&null!=K(e,e.spatialReference,t,r,n)}function K(e,t,r,n,i){se[0]=e.x,se[1]=e.y;const s=e.z;return se[2]=void 0!==s?s:i,(0,v.projectBuffer)(se,t,0,se,n,0)?(r.x=se[0],r.y=se[1],r.spatialReference=n,void 0!==s||(0,u.xP)(n)?(r.z=se[2],r.hasZ=!0):(r.z=void 0,r.hasZ=!1),void 0===e.m?(r.m=void 0,r.hasM=!1):(r.m=e.m,r.hasM=!0),r):null}function W(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=V(e,e.spatialReference,t,r,n)}function V(e,t,r,n,i){const{points:s,hasZ:o,hasM:l}=e,a=[],p=s.length,c=[];for(const e of s)c.push(e[0],e[1],o?e[2]:i);if(!(0,v.projectBuffer)(c,t,0,c,n,0,p))return null;const d=o||(0,u.xP)(n);for(let e=0;e<p;++e){const t=3*e,r=c[t],n=c[t+1];d&&l?a.push([r,n,c[t+2],s[e][3]]):d?a.push([r,n,c[t+2]]):l?a.push([r,n,s[e][2]]):a.push([r,n])}return r.points=a,r.spatialReference=n,r.hasZ=o,r.hasM=l,r}function Y(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=X(e,e.spatialReference,t,r,n)}function X(e,t,r,n,i){const{paths:s,hasZ:o,hasM:l}=e,a=[];if(!ie(s,o??!1,l??!1,t,a,n,i))return null;const p=o||(0,u.xP)(n);return r.paths=a,r.spatialReference=n,r.hasZ=p,r.hasM=l,r}function ee(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=te(e,e.spatialReference,t,r,n)}function te(e,t,r,n,i){const{rings:s,hasZ:o,hasM:l}=e,a=[];if(!ie(s,o??!1,l??!1,t,a,n,i))return null;const p=o||(0,u.xP)(n);return r.rings=a,r.spatialReference=n,r.hasZ=p,r.hasM=l,r}function re(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=ne(e,e.spatialReference,t,r,n)}function ne(e,t,r,n,i){const{xmin:s,ymin:o,xmax:l,ymax:a,hasZ:p,hasM:c}=e;if(!C(s,o,p?e.zmin:i,t,se,n))return null;const d=p||(0,u.xP)(n);return r.xmin=se[0],r.ymin=se[1],d&&(r.zmin=se[2]),C(l,a,p?e.zmax:i,t,se,n)?(r.xmax=se[0],r.ymax=se[1],d&&(r.zmax=se[2]),c&&(r.mmin=e.mmin,r.mmax=e.mmax),r.spatialReference=n,r):null}function ie(e,t,r,n,i,s,o=0){const l=new Array;for(const r of e)for(const e of r)l.push(e[0],e[1],t?e[2]:o);if(!(0,v.projectBuffer)(l,n,0,l,s,0))return!1;let a=0;i.length=0;const p=t||(0,u.xP)(s);for(const t of e){const e=new Array;for(const n of t)p&&r?e.push([l[a++],l[a++],l[a++],n[3]]):p?e.push([l[a++],l[a++],l[a++]]):r?(e.push([l[a++],l[a++],n[2]]),a++):(e.push([l[a++],l[a++]]),a++);i.push(e)}return!0}const se=(0,l.vt)()},91880:(e,t,r)=>{r.d(t,{A:()=>p});var n,i=r(31635),s=r(66552),o=r(25482),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({asc:"ascending",desc:"descending"});let p=class extends o.o{static{n=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new n({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,i.Cg)([(0,l.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=n=(0,i.Cg)([(0,a.$)("esri.layers.support.OrderByInfo")],p)},96184:(e,t,r)=>{r.d(t,{A:()=>f});var n=r(31635),i=r(69540),s=r(25482),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(64108),u=r(43937),p=r(79677),c=r(10184),d=r(56400);function y(e,t){return c.A.fromJSON({value:e,unit:t})}let f=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?p.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?y(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?y(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],f.prototype,"cumulative",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"endField",void 0),(0,n.Cg)([(0,o.MZ)({type:p.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"fullTimeExtent",void 0),(0,n.Cg)([(0,l.w)("fullTimeExtent",["timeExtent"])],f.prototype,"readFullTimeExtent",null),(0,n.Cg)([(0,u.K)("fullTimeExtent")],f.prototype,"writeFullTimeExtent",null),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"hasLiveData",void 0),(0,n.Cg)([(0,o.MZ)({type:c.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"interval",void 0),(0,n.Cg)([(0,l.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],f.prototype,"readInterval",null),(0,n.Cg)([(0,u.K)("interval")],f.prototype,"writeInterval",null),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"startField",void 0),(0,n.Cg)([(0,o.MZ)((0,d.P6)("timeReference",!0))],f.prototype,"timeZone",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"trackIdField",void 0),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],f.prototype,"useTime",void 0),(0,n.Cg)([(0,o.MZ)({type:[Date],json:{read:!1}})],f.prototype,"stops",void 0),f=(0,n.Cg)([(0,a.$)("esri.layers.support.TimeInfo")],f)},99157:(e,t,r)=>{r.d(t,{A:()=>a});var n,i=r(31635),s=r(69622),o=r(10107),l=(r(44208),r(53966),r(87811),r(64108));let a=n=class extends s.A{constructor(e){super(e),this.isInverse=!1,this.wkt=null,this.wkid=null}getInverse(){return new n({isInverse:!this.isInverse,wkid:this.wkid,wkt:this.wkt})}};(0,i.Cg)([(0,o.MZ)()],a.prototype,"isInverse",void 0),(0,i.Cg)([(0,o.MZ)()],a.prototype,"wkt",void 0),(0,i.Cg)([(0,o.MZ)()],a.prototype,"wkid",void 0),a=n=(0,i.Cg)([(0,l.$)("esri.geometry.operators.support.GeographicTransformationStep")],a)},99352:(e,t,r)=>{r.d(t,{F:()=>n,P:()=>i});const n={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},i={supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3106],{159:(e,t,r)=>{r.d(t,{A:()=>u});var n,i=r(31635),s=r(69622),o=r(10107),l=(r(44208),r(53966),r(87811),r(64108)),a=r(99157);let u=n=class extends s.A{constructor(e){super(e),this.steps=[]}getInverse(){const e=new n;for(let t=this.steps.length-1;t>=0;t--){const r=this.steps[t];e.steps.push(r.getInverse())}return e}};(0,i.Cg)([(0,o.MZ)({type:[a.A],nonNullable:!0})],u.prototype,"steps",void 0),u=n=(0,i.Cg)([(0,l.$)("esri.geometry.operators.support.GeographicTransformation")],u)},6455:(e,t,r)=>{r.d(t,{FJ:()=>v,Dp:()=>w,KV:()=>C});var n=r(31635),i=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(64108)),l=r(89317),a=r(69540),u=r(7762),p=r(25482),c=r(43937),d=r(83960),y=r(13069);const f={write:{overridePolicy:(e,t,r)=>({enabled:!r||"scale"===r.filterMode})}};let h=class extends((0,a.OU)(p.o)){constructor(e){super(e),this.id=(0,y.lk)(),this.maxScale=0,this.minScale=0,this.title="",this.where=null}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"id",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:f})],h.prototype,"maxScale",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:f})],h.prototype,"minScale",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"title",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],h.prototype,"where",void 0),h=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilter")],h);var g=r(41560);let m=class extends((0,a.OU)(p.o)){constructor(e){super(e),this.activeFilterId=null,this.filters=new(u.A.ofType(h)),this.mode="manual"}writeFilters(e,t,r,n){const i=e.toArray();"scale"===this.mode&&i.sort((e,t)=>{const r=(0,d.oW)(t.minScale,e.minScale),n=e.maxScale-t.maxScale;return 0===r?n:r}),t[r]=i.map(e=>e.toJSON(n))}write(e,t){return super.write(e,(0,g.mW)(this,t))}};(0,n.Cg)([(0,s.MZ)({type:String,json:{write:{overridePolicy:(e,t,r)=>({enabled:"manual"===r.filterMode,isRequired:!0})}}})],m.prototype,"activeFilterId",void 0),(0,n.Cg)([(0,s.MZ)({type:u.A.ofType(h),nonNullable:!0,json:{write:!0}})],m.prototype,"filters",void 0),(0,n.Cg)([(0,c.K)("filters")],m.prototype,"writeFilters",null),(0,n.Cg)([(0,s.MZ)({type:["manual","scale"],nonNullable:!0,json:{name:"filterMode",write:!0}})],m.prototype,"mode",void 0),m=(0,n.Cg)([(0,o.$)("esri.layers.support.DisplayFilterInfo")],m);const v=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.displayFilterEnabled=!0,this.displayFilterInfo=null}};return(0,n.Cg)([(0,s.MZ)(w)],r.prototype,"displayFilterEnabled",void 0),(0,n.Cg)([(0,s.MZ)(C)],r.prototype,"displayFilterInfo",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.DisplayFilteredLayer")],r),r},w={type:Boolean,json:{name:"layerDefinition.disableDisplayFilter",read:{reader:e=>!e},write:{layerContainerTypes:l.K,writer(e,t,r){(0,i.sM)(r,!e,t)}},origins:{"web-scene":{write:!1,read:!1}}}},C={type:m,json:{name:"layerDefinition.displayFilterInfo",write:{enabled:!0,allowNull:!0,layerContainerTypes:l.K},origins:{"web-scene":{write:!1,read:!1}}}}},8303:(e,t,r)=>{r.d(t,{A:()=>I});var n=r(31635),i=r(92602),s=r(70333),o=r(11254),l=r(60999),a=r(49186),u=r(53966),p=r(97768),c=r(74887),d=r(84952),y=r(10107),f=(r(44208),r(87811),r(36005)),h=r(64108),g=r(43937),m=r(77548),v=r(20655),w=r(80812),C=r(41318),M=r(10407);const I=e=>{const t=e;let I=class extends t{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new w.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:n}=await r.e(1204).then(r.bind(r,41204));return(0,c.Te)(t),await n({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,c.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,c.QP)(e),!0)))}async setUserPrivileges(e,t){if(!i.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:n},content:{updateItem:i}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",n),this._set("userHasUpdateItemPrivileges",i)}catch(e){(0,c.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const n=!s.id?.findCredential(this.url),i=e===r.id;if(i&&r.portal.user)return this._getUserPrivileges(r,n);let o,l;if(i)o=r.portal.url;else try{o=await(0,m.wI)(this.url,t)}catch(e){(0,c.QP)(e)}if(!o||!(0,d.b8)(o,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;l=await(s.id?.getCredential(`${o}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,c.QP)(e)}const a=!0,u=!1,p=!1;if(!l)return{features:{edit:a,fullEdit:u},content:{updateItem:p}};try{if(i?await r.reload():(r=new w.default({id:e,portal:{url:o}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,n)}catch(e){(0,c.QP)(e)}return{features:{edit:a,fullEdit:u},content:{updateItem:p}}}_getUserPrivileges(e,t){const r=(0,M.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,c.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?s.id?.findCredential(this.url):null;if(!t)return!0;const r=x.credential===t?x.user:await this._fetchEditingUser(e);return x.credential=t,x.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=s.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const n=`${r.owningSystemUrl}/sharing/rest`,i=v.A.getDefault();if(i&&i.loaded&&(0,d.S8)(i.restUrl)===(0,d.S8)(n))return i.user;const a=`${n}/community/self`,u=null!=e?e.signal:null,p=await(0,l.Ke)((0,o.A)(a,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?C.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,n=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return r&&n&&!(0,d.ut)(n.restUrl,r.restUrl)?(t.messages&&t.messages.push(new a.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,n.Cg)([(0,y.MZ)({type:w.default})],I.prototype,"portalItem",null),(0,n.Cg)([(0,f.w)("web-document","portalItem",["itemId"])],I.prototype,"readPortalItem",null),(0,n.Cg)([(0,g.K)("web-document","portalItem",{itemId:{type:String}})],I.prototype,"writePortalItem",null),(0,n.Cg)([(0,y.MZ)({clonable:!1})],I.prototype,"resourceReferences",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasEditingPrivileges",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasFullEditingPrivileges",void 0),(0,n.Cg)([(0,y.MZ)({type:Boolean,readOnly:!0})],I.prototype,"userHasUpdateItemPrivileges",void 0),I=(0,n.Cg)([(0,h.$)("esri.layers.mixins.PortalLayer")],I),I},x={credential:null,user:null}},9762:(e,t,r)=>{r.r(t),r.d(t,{projectBuffer:()=>i});var n=r(37539);function i(e,t,r,i,s,o,l=Math.floor(e.length/3)){const a=(0,n.jd)(t,s);if(null==a)return!1;if(a===n.pO){if(e===i&&r===o)return!0;const t=r+3*l;for(let n=r,s=o;n<t;n++,s++)i[s]=e[n];return!0}const u=r+3*l;for(let t=r,n=o;t<u;t+=3,n+=3)a(e,t,i,n);return!0}},10184:(e,t,r)=>{r.d(t,{A:()=>c});var n=r(31635),i=r(69540),s=r(25482),o=r(88930),l=r(10107),a=(r(44208),r(53966),r(87811),r(93223)),u=r(64108),p=r(73133);let c=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.t)(this.value,this.unit,"milliseconds")}};(0,n.Cg)([(0,a.e)(p.j,{nonNullable:!0})],c.prototype,"unit",void 0),(0,n.Cg)([(0,l.MZ)({type:Number,json:{write:!0},nonNullable:!0})],c.prototype,"value",void 0),c=(0,n.Cg)([(0,u.$)("esri.time.TimeInterval")],c)},10407:(e,t,r)=>{r.d(t,{It:()=>y,LG:()=>o,OM:()=>u,Sm:()=>p,Y:()=>l,bK:()=>a,mm:()=>d,sQ:()=>c});var n=r(91218),i=r(16930),s=r(28735);function o(e,t){if(!l(e,t)){const r=e.typeKeywords;r?r.push(t):e.typeKeywords=[t]}}function l(e,t){return!!e.typeKeywords?.includes(t)}function a(e){return l(e,d.HOSTED_SERVICE)}function u(e,t){const r=e.typeKeywords;if(r){const e=r.indexOf(t);e>-1&&r.splice(e,1)}}function p(e,t,r){r?o(e,t):u(e,t)}async function c(e){const t=e.clone().normalize();let r;if(t.length>1)for(const e of t)r?e.width>r.width&&(r=e):r=e;else r=t[0];return async function(e){const t=e.spatialReference;if(t.isWGS84)return e.clone();if(t.isWebMercator)return(0,s.ci)(e);const r=i.A.WGS84;return await(0,n.initializeProjection)(t,r),(0,n.project)(e,r)}(r)}const d={CHARTS:"Charts",DYNAMIC:"Dynamic",DEVELOPER_BASEMAP:"DeveloperBasemap",GROUP_LAYER_MAP:"Map",HOSTED_SERVICE:"Hosted Service",JSAPI:"ArcGIS API for JavaScript",LOCAL_SCENE:"ViewingMode-Local",METADATA:"Metadata",MULTI_LAYER:"Multilayer",ORIENTED_IMAGERY_LAYER:"OrientedImageryLayer",SINGLE_LAYER:"Singlelayer",SUBTYPE_GROUP_LAYER:"SubtypeGroupLayer",SUBTYPE_GROUP_TABLE:"SubtypeGroupTable",TABLE:"Table",TILED_IMAGERY:"Tiled Imagery"};function y(e){const{portal:t,isOrgItem:r,itemControl:n}=e,i=t.user?.privileges;let s=!i||i.includes("features:user:edit"),o=!!r&&!!i?.includes("features:user:fullEdit");const l="update"===n||"admin"===n;return l?o=s=!0:o&&(s=!0),{features:{edit:s,fullEdit:o},content:{updateItem:l}}}},17036:(e,t,r)=>{r.d(t,{p:()=>a});var n=r(44208),i=r(53966),s=r(20437),o=r(95466),l=r(30524);function a(){return{fields:{type:[s.A],value:null,set:function(e){if(e&&(0,n.A)("big-integer-warning-enabled")){const t=e.filter(e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8);if(t.length){const e=t.map(e=>`'${e.name}'`).join(", ");i.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return o.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||i.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,l.DB)(this.fieldsIndex,e)}}}}},22671:(e,t,r)=>{r.d(t,{A:()=>v});var n,i=r(31635),s=r(52106),o=r(66552),l=r(25482),a=r(4718),u=r(10107),p=(r(44208),r(53966),r(36005)),c=r(64108),d=r(43937),y=r(16930),f=r(65864),h=r(50498),g=r(20437);const m=new o.J({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let v=n=class extends l.o{constructor(e){super(e),this.displayFieldName=null,this.exceededTransferLimit=!1,this.features=[],this.fields=null,this.geometryType=null,this.hasM=!1,this.hasZ=!1,this.queryGeometry=null,this.spatialReference=null}readFeatures(e,t){return this.readFeaturesWithClass(e,t,s.A)}writeGeometryType(e,t,r,n){if(e)return void m.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void m.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,f.rS)(e);return n&&!r&&t.spatialReference&&(n.spatialReference=y.A.fromJSON(t.spatialReference)),n}writeSpatialReference(e,t){if(e)return void(t.spatialReference=e.toJSON());const{features:r}=this;if(r)for(const e of r)if(e&&null!=e.geometry&&e.geometry.spatialReference)return void(t.spatialReference=e.geometry.spatialReference.toJSON())}clone(){return new n(this.cloneProperties())}cloneProperties(){return(0,a.o8)({displayFieldName:this.displayFieldName,exceededTransferLimit:this.exceededTransferLimit,features:this.features,fields:this.fields,geometryType:this.geometryType,hasM:this.hasM,hasZ:this.hasZ,queryGeometry:this.queryGeometry,spatialReference:this.spatialReference,transform:this.transform})}toJSON(e){const t=this.write();if(t.features&&Array.isArray(e)&&e.length>0)for(let r=0;r<t.features.length;r++){const n=t.features[r];if(n.geometry){const t=e?.[r];n.geometry=t?.toJSON()||n.geometry}}return t}quantize(e){const{scale:[t,r],translate:[n,i]}=e,s=this.features,o=this._getQuantizationFunction(this.geometryType,e=>Math.round((e-n)/t),e=>Math.round((i-e)/r));for(let e=0,t=s.length;e<t;e++)o?.(s[e].geometry)||(s.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[n,i],scale:[s,o]}=r;let l=null,a=null;if(this.hasZ&&null!=r?.scale?.[2]){const{translate:[,,e],scale:[,,t]}=r;l=r=>r*t+e}if(this.hasM&&null!=r?.scale?.[3]){const{translate:[,,,e],scale:[,,,t]}=r;a=r=>null==r?r:r*t+e}const u=this._getHydrationFunction(e,e=>e*s+n,e=>i-e*o,l,a);for(const{geometry:e}of t)null!=e&&u&&u(e);return this.transform=null,this}readFeaturesWithClass(e,t,r){const n=y.A.fromJSON(t.spatialReference),i=[];for(let t=0;t<e.length;t++){const s=e[t],o=r.fromJSON(s),l=s.geometry?.spatialReference;null==o.geometry||l||(o.geometry.spatialReference=n);const a=s.aggregateGeometries,u=o.aggregateGeometries;if(a&&null!=u)for(const e in u){const t=u[e],r=a[e],i=r?.spatialReference;null==t||i||(t.spatialReference=n)}i.push(o)}return i}_quantizePoints(e,t,r){let n,i;const s=[];for(let o=0,l=e.length;o<l;o++){const l=e[o];if(o>0){const e=t(l[0]),o=r(l[1]);e===n&&o===i||(s.push([e-n,o-i]),n=e,i=o)}else n=t(l[0]),i=r(l[1]),s.push([n,i])}return s.length>0?s:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const n=(0,f.Bi)(e)?e.rings:e.paths,i=[];for(let e=0,s=n.length;e<s;e++){const s=n[e],o=this._quantizePoints(s,t,r);o&&i.push(o)}return i.length>0?((0,f.Bi)(e)?e.rings=i:e.paths=i,e):null}:"multipoint"===e?e=>{const n=this._quantizePoints(e.points,t,r);return n&&n.length>0?(e.points=n,e):null}:"extent"===e?e=>e:null}_getHydrationFunction(e,t,r,n,i){return"point"===e?e=>{e.x=t(e.x),e.y=r(e.y),n&&(e.z=n(e.z))}:"polyline"===e||"polygon"===e?e=>{const s=(0,f.Bi)(e)?e.rings:e.paths;let o,l;for(let e=0,n=s.length;e<n;e++){const n=s[e];for(let e=0,i=n.length;e<i;e++){const i=n[e];e>0?(o+=i[0],l+=i[1]):(o=i[0],l=i[1]),i[0]=t(o),i[1]=r(l)}}if(n&&i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=n(r[2]),r[3]=i(r[3])}}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=n(r[2])}}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];for(let e=0,r=t.length;e<r;e++){const r=t[e];r[2]=i(r[2])}}}:"extent"===e?e=>{e.xmin=t(e.xmin),e.ymin=r(e.ymin),e.xmax=t(e.xmax),e.ymax=r(e.ymax),n&&null!=e.zmax&&null!=e.zmin&&(e.zmax=n(e.zmax),e.zmin=n(e.zmin)),i&&null!=e.mmax&&null!=e.mmin&&(e.mmax=i(e.mmax),e.mmin=i(e.mmin))}:"multipoint"===e?e=>{const s=e.points;let o,l;for(let e=0,n=s.length;e<n;e++){const n=s[e];e>0?(o+=n[0],l+=n[1]):(o=n[0],l=n[1]),n[0]=t(o),n[1]=r(l)}if(n&&i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=n(t[2]),t[3]=i(t[3])}else if(n)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=n(t[2])}else if(i)for(let e=0,t=s.length;e<t;e++){const t=s[e];t[2]=i(t[2])}}:null}};(0,i.Cg)([(0,u.MZ)({type:String,json:{write:!0}})],v.prototype,"displayFieldName",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"exceededTransferLimit",void 0),(0,i.Cg)([(0,u.MZ)({type:[s.A],json:{write:!0}})],v.prototype,"features",void 0),(0,i.Cg)([(0,p.w)("features")],v.prototype,"readFeatures",null),(0,i.Cg)([(0,u.MZ)({type:[g.A],json:{write:!0}})],v.prototype,"fields",void 0),(0,i.Cg)([(0,u.MZ)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:m.read}}})],v.prototype,"geometryType",void 0),(0,i.Cg)([(0,d.K)("geometryType")],v.prototype,"writeGeometryType",null),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasM",void 0),(0,i.Cg)([(0,u.MZ)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],v.prototype,"hasZ",void 0),(0,i.Cg)([(0,u.MZ)({types:h.yR,json:{write:!0}})],v.prototype,"queryGeometry",void 0),(0,i.Cg)([(0,p.w)("queryGeometry")],v.prototype,"readQueryGeometry",null),(0,i.Cg)([(0,u.MZ)({type:y.A,json:{write:!0}})],v.prototype,"spatialReference",void 0),(0,i.Cg)([(0,d.K)("spatialReference")],v.prototype,"writeSpatialReference",null),(0,i.Cg)([(0,u.MZ)({json:{write:!0}})],v.prototype,"transform",void 0),v=n=(0,i.Cg)([(0,c.$)("esri.rest.support.FeatureSet")],v),v.prototype.toJSON.isDefaultToJSON=!0},29005:(e,t,r)=>{r.d(t,{A:()=>p});var n=r(31635),i=r(69540),s=r(66552),o=r(25482),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let p=class extends((0,i.OU)(o.o)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"name",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"description",void 0),(0,n.Cg)([(0,l.MZ)({json:{read:u.read,write:u.write}})],p.prototype,"drawingTool",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"prototype",void 0),(0,n.Cg)([(0,l.MZ)({json:{write:!0}})],p.prototype,"thumbnail",void 0),p=(0,n.Cg)([(0,a.$)("esri.layers.support.FeatureTemplate")],p)},32756:(e,t,r)=>{r.d(t,{Rr:()=>a,fY:()=>p,ne:()=>u});var n=r(31635),i=r(93637),s=r(10107),o=(r(44208),r(53966),r(87811),r(64108)),l=r(91880);function a(e,t,r){if(!e)return null;const n=e.find(e=>!!e.field);if(!n)return null;const i=new l.A;return i.read(n,r),[i]}const u={type:[l.A],json:{origins:{"web-scene":{write:!1,read:!1}},name:"layerDefinition.orderBy",read:{reader:a},write:{writer:function(e,t,r,n){const s=e.find(e=>!!e.field);s&&(0,i.sM)(r,[s.toJSON()],t)}}}},p=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.orderBy=null}};return(0,n.Cg)([(0,s.MZ)(u)],r.prototype,"orderBy",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.OrderedLayer")],r),r}},33143:(e,t,r)=>{r.d(t,{A:()=>d});var n=r(31635),i=r(69540),s=r(25482),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(64108),u=r(43937),p=r(80451),c=r(29005);let d=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.id=null,this.name=null,this.domains=null,this.templates=null}readDomains(e){const t={};for(const r of Object.keys(e))t[r]=(0,p.rS)(e[r]);return t}writeDomains(e,t){const r={};for(const t of Object.keys(e))e[t]&&(r[t]=e[t]?.toJSON());t.domains=r}};(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"id",void 0),(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"name",void 0),(0,n.Cg)([(0,o.MZ)({json:{write:!0}})],d.prototype,"domains",void 0),(0,n.Cg)([(0,l.w)("domains")],d.prototype,"readDomains",null),(0,n.Cg)([(0,u.K)("domains")],d.prototype,"writeDomains",null),(0,n.Cg)([(0,o.MZ)({type:[c.A],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,n.Cg)([(0,a.$)("esri.layers.support.FeatureType")],d)},37539:(e,t,r)=>{r.d(t,{pO:()=>h,jd:()=>d,Tp:()=>y,w5:()=>c});var n=r(34727),i=r(83047),s=r(73941),o=r(79258);Math.PI;const l=o.$O.radius,a=o.$O.eccentricitySquared,u={a1:l*a,a2:l*a*l*a,a3:l*a*a/2,a4:l*a*l*a*2.5,a5:l*a+l*a*a/2,a6:1-a};o.$O.radius,o.$O.flattening,o.Sw.radius,o.Sw.flattening,o.sH.radius,o.sH.flattening,o.sH.radius;var p=r(21325);const c={2:{5:h,7:null,9:null,10:h,1:x,6:null,8:null,0:null,3:m,11:v,2:h,4:O},5:{5:h,7:null,9:null,10:h,1:x,6:null,8:null,0:null,3:m,11:v,2:h,4:O},7:{5:null,7:h,9:null,10:h,1:null,6:I,8:null,0:null,3:null,11:null,2:null,4:null},9:{5:null,7:null,9:h,10:h,1:null,6:null,8:M,0:null,3:null,11:null,2:null,4:null},3:{5:g,7:null,9:null,10:g,1:function(e,t,r,n){const i=e[t]/E,s=j-2*Math.atan(Math.exp(-e[t+1]/E)),o=E+e[t+2],l=Math.cos(s)*o;r[n]=Math.cos(i)*l,r[n+1]=Math.sin(i)*l,r[n+2]=Math.sin(s)*o},6:null,8:null,0:null,3:h,11:function(e,t,r,n){g(e,t,r,n),v(r,n,r,n)},2:g,4:function(e,t,r,n){g(e,t,r,n),O(r,n,r,n)}},4:{5:P,7:null,9:null,10:P,1:function(e,t,r,n){P(e,t,r,n),x(r,n,r,n)},6:null,8:null,0:null,3:function(e,t,r,n){P(e,t,r,n),m(r,n,r,n)},11:function(e,t,r,n){P(e,t,r,n),v(r,n,r,n)},2:P,4:h},1:{5:R,7:null,9:null,10:R,1:h,6:null,8:null,0:null,3:function(e,t,r,n){R(e,t,r,n),m(r,n,r,n)},11:function(e,t,r,n){R(e,t,r,n),v(r,n,r,n)},2:R,4:function(e,t,r,n){R(e,t,r,n),O(r,n,r,n)}},6:{5:null,7:T,9:null,10:T,1:null,6:h,8:null,0:null,3:null,11:null,2:null,4:null},8:{5:null,7:null,9:A,10:A,1:null,6:null,8:h,0:null,3:null,11:null,2:null,4:null},0:{5:null,7:null,9:null,10:null,1:null,6:null,8:null,0:h,3:null,11:null,2:null,4:null},10:{5:h,7:h,9:h,10:h,1:x,6:I,8:M,0:null,3:m,11:v,2:h,4:O},11:{5:w,7:null,9:null,10:w,1:function(e,t,r,n){w(e,t,r,n),x(r,n,r,n)},6:null,8:null,0:null,3:function(e,t,r,n){w(e,t,r,n),m(r,n,r,n)},11:h,2:w,4:function(e,t,r,n){w(e,t,r,n),O(r,n,r,n)}}};function d(e,t){return y(e,t)?.projector}function y(e,t){if(null==e||null==t)return null;if(F.source.spatialReference===e&&F.dest.spatialReference===t)return F;const r=f(e,F.source),n=f(t,F.dest);return 0===r&&0===n?(0,p.aI)(e,t)?F.projector=h:F.projector=null:F.projector=c[r][n],F}function f(e,t){return e?t.spatialReference===e?t.spatialReferenceId:(t.spatialReference=e,"metersPerUnit"in t&&(t.metersPerUnit=(0,i.GA)(e,1)),(0,s.jA)(e)?t.spatialReferenceId=1:(0,p.oT)(e)?t.spatialReferenceId=2:(0,p.K8)(e)?t.spatialReferenceId=3:(0,p.r1)(e)?t.spatialReferenceId=11:e.wkt===s.Ro.wkt?t.spatialReferenceId=4:4490===e.wkid?t.spatialReferenceId=5:e.wkt===s.FY.wkt?t.spatialReferenceId=6:e.wkt===s.LJ.wkt?t.spatialReferenceId=8:(0,p.q8)(e)?t.spatialReferenceId=7:(0,p.KQ)(e)?t.spatialReferenceId=9:t.spatialReferenceId=0):0}function h(e,t,r,n){e!==r&&(r[n++]=e[t++],r[n++]=e[t++],r[n]=e[t])}function g(e,t,r,n){r[n]=Z*(e[t]/E),r[n+1]=Z*(j-2*Math.atan(Math.exp(-e[t+1]/E))),r[n+2]=e[t+2]}function m(e,t,r,i){!function(e,t,r,i,s){const o=.4999999*Math.PI,l=(0,n.qE)(b*e[t+1],-o,o),a=Math.sin(l);r[i++]=b*e[t]*s.radius,r[i++]=s.halfSemiMajorAxis*Math.log((1+a)/(1-a)),r[i]=e[t+2]}(e,t,r,i,o.$O)}function v(e,t,r,n){r[n]=e[t]*D,r[n+1]=e[t+1]*D,r[n+2]=e[t+2]}function w(e,t,r,n){r[n]=e[t]*U,r[n+1]=e[t+1]*U,r[n+2]=e[t+2]}function C(e,t,r,n,i){const s=i+e[t+2],o=b*e[t+1],l=b*e[t],a=Math.cos(o)*s;r[n]=Math.cos(l)*a,r[n+1]=Math.sin(l)*a,r[n+2]=Math.sin(o)*s}function M(e,t,r,n){C(e,t,r,n,o.Sw.radius)}function I(e,t,r,n){C(e,t,r,n,o.sH.radius)}function x(e,t,r,n){C(e,t,r,n,o.$O.radius)}function S(e,t,r,i,s){const o=e[t],l=e[t+1],a=e[t+2],u=Math.sqrt(o*o+l*l+a*a),p=(0,n.YN)(a/(0===u?1:u)),c=Math.atan2(l,o);r[i++]=Z*c,r[i++]=Z*p,r[i]=u-s}function A(e,t,r,n){S(e,t,r,n,o.Sw.radius)}function T(e,t,r,n){S(e,t,r,n,o.sH.radius)}function R(e,t,r,n){S(e,t,r,n,o.$O.radius)}function O(e,t,r,n){!function(e,t,r,n,i){const s=b*e[t],o=b*e[t+1],l=e[t+2],a=Math.sin(o),u=Math.cos(o),p=i.radius/Math.sqrt(1-i.eccentricitySquared*a*a);r[n++]=(p+l)*u*Math.cos(s),r[n++]=(p+l)*u*Math.sin(s),r[n++]=(p*(1-i.eccentricitySquared)+l)*a}(e,t,r,n,o.$O)}function P(e,t,r,n){const i=u,s=e[t],l=e[t+1],a=e[t+2];let p,c,d,y,f,h,g,m,v,w,C,M,I,x,S,A,T,R,O,P,F;p=Math.abs(a),c=s*s+l*l,d=Math.sqrt(c),y=c+a*a,f=Math.sqrt(y),P=Math.atan2(l,s),h=a*a/y,g=c/y,x=i.a2/f,S=i.a3-i.a4/f,g>.3?(m=p/f*(1+g*(i.a1+x+h*S)/f),O=Math.asin(m),w=m*m,v=Math.sqrt(1-w)):(v=d/f*(1-h*(i.a5-x-g*S)/f),O=Math.acos(v),w=1-v*v,m=Math.sqrt(w)),C=1-o.$O.eccentricitySquared*w,M=o.$O.radius/Math.sqrt(C),I=i.a6*M,x=d-M*v,S=p-I*m,T=v*x+m*S,A=v*S-m*x,R=A/(I/C+T),O+=R,F=T+A*R/2,a<0&&(O=-O),r[n++]=Z*P,r[n++]=Z*O,r[n]=F}const F={source:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},dest:{spatialReference:null,spatialReferenceId:0,metersPerUnit:1},projector:h},b=(0,n.kU)(1),Z=(0,n.KJ)(1),j=.5*Math.PI,E=o.$O.radius,D=E*Math.PI/180,U=180/(E*Math.PI)},52136:(e,t,r)=>{r.d(t,{p:()=>o});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108));const o=e=>{const t=e;let r=class extends t{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,n.Cg)([(0,i.MZ)({type:String})],r.prototype,"apiKey",null),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.APIKeyMixin")],r),r}},62815:(e,t,r)=>{r.d(t,{N:()=>o});var n=r(83047),i=r(73941),s=r(21325);function o(e,t,r){if(null==t||null==r||r.vcsWkid||(0,s.aI)(t,r)||(0,i.xP)(t)||(0,i.xP)(r))return null;const o=(0,n.G9)(t)/(0,n.G9)(r);if(1===o)return null;switch(e){case"point":case"esriGeometryPoint":return e=>function(e,t){null!=e?.z&&(e.z*=t)}(e,o);case"polyline":case"esriGeometryPolyline":return e=>function(e,t){if(e)for(const r of e.paths)for(const e of r)e.length>2&&(e[2]*=t)}(e,o);case"polygon":case"esriGeometryPolygon":return e=>function(e,t){if(e)for(const r of e.rings)for(const e of r)e.length>2&&(e[2]*=t)}(e,o);case"multipoint":case"esriGeometryMultipoint":return e=>function(e,t){if(e)for(const r of e.points)r.length>2&&(r[2]*=t)}(e,o);case"extent":case"esriGeometryEnvelope":return e=>function(e,t){e&&null!=e.zmin&&null!=e.zmax&&(e.zmin*=t,e.zmax*=t)}(e,o);default:return null}}},63396:(e,t,r)=>{r.d(t,{d:()=>x});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108)),o=r(60950),l=r(99959);class a extends l.A{constructor(e){super(),this.type="track",this.trackInfoProvider=e}get id(){return this.trackInfoProvider.id}get[o.ym](){return this.trackInfoProvider.trackInfo}}var u=r(37838),p=r(69540),c=r(25482),d=r(93637),y=r(43937),f=r(50820),h=r(10873),g=r(46499),m=r(41214);let v=class extends((0,p.OU)(c.o)){constructor(e){super(e),this.labelingInfo=null,this.labelsVisible=!0,this.renderer=null,this.visible=!0}};(0,n.Cg)([(0,i.MZ)({type:[g.A],json:{write:!0}})],v.prototype,"labelingInfo",void 0),(0,n.Cg)([(0,i.MZ)(h.kF)],v.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,i.MZ)({types:m.Hg,json:{write:!0}})],v.prototype,"renderer",void 0),(0,n.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],v.prototype,"visible",void 0),v=(0,n.Cg)([(0,s.$)("esri.layers.support.TrackPartInfo")],v);var w=r(96576),C=r(59868),M=r(10184);let I=class extends((0,p.OU)(c.o)){constructor(e){super(e),this.enabled=!0,this.fields=[],this.latestObservations=new v({renderer:new w.A({symbol:C.UK.clone()})}),this.maxDisplayDuration=null,this.maxDisplayObservationsPerTrack=0,this.popupEnabled=!0,this.popupTemplate=null,this.previousObservations=new v({renderer:new w.A({symbol:C.UK.clone()})}),this.trackLines=new v({renderer:new w.A({symbol:C.A7.clone()})}),this.timeField="startTimeField"}writeFields(e,t,r){const n=e.filter(e=>"avg_angle"!==e.statisticType).map(e=>e.toJSON());(0,d.sM)(r,n,t)}};(0,n.Cg)([(0,i.MZ)({type:Boolean,json:{write:!0}})],I.prototype,"enabled",void 0),(0,n.Cg)([(0,i.MZ)({type:[f.A],json:{write:!0}})],I.prototype,"fields",void 0),(0,n.Cg)([(0,y.K)("fields")],I.prototype,"writeFields",null),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"latestObservations",void 0),(0,n.Cg)([(0,i.MZ)({type:M.A,json:{write:!0}})],I.prototype,"maxDisplayDuration",void 0),(0,n.Cg)([(0,i.MZ)({type:Number,json:{write:!0}})],I.prototype,"maxDisplayObservationsPerTrack",void 0),(0,n.Cg)([(0,i.MZ)(h.M6)],I.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,i.MZ)({type:u.A,json:{name:"popupInfo",write:!0}})],I.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"previousObservations",void 0),(0,n.Cg)([(0,i.MZ)({type:v,json:{write:!0}})],I.prototype,"trackLines",void 0),(0,n.Cg)([(0,i.MZ)({type:["timeReceived","startTimeField","endTimeField"],json:{read:!0,write:!0}})],I.prototype,"timeField",void 0),I=(0,n.Cg)([(0,s.$)("esri.layers.support.TrackInfo")],I);const x=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.trackGraphicOrigin=new a(this),this.trackInfo=null}};return(0,n.Cg)([(0,i.MZ)({readOnly:!0,clonable:!1})],r.prototype,"trackGraphicOrigin",void 0),(0,n.Cg)([(0,i.MZ)({type:I})],r.prototype,"trackInfo",void 0),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.TrackableLayer")],r),r}},64714:(e,t,r)=>{r.d(t,{F0:()=>l,Vx:()=>p,e2:()=>d,f:()=>y});var n=r(44208),i=r(4718),s=r(99352),o=r(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 p(e,t){if((0,n.A)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let r=`this${c(t)} = null;`;for(const t in e)r+=`this${c(t)} = ${JSON.stringify(e[t])};`;const n=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${r};\n }\n }\n `)();return()=>new n}catch(r){return()=>({[t]:null,...e})}}function c(e){return a.test(e)?`.${e}`:`["${e}"]`}function d(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,i.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,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:s.F,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:s.P,editing:{supportsGeometryUpdate:t,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateWithoutM:!1,supportsUploadWithItemId:!1,supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}},65977:(e,t,r)=>{r.r(t),r.d(t,{default:()=>V});var n=r(31635),i=r(37838),s=r(49186),o=r(25728),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108)),u=r(5443),p=r(16930),c=r(50498),d=r(55156),y=r(60950),f=r(89808),h=r(99959);const g=Symbol("isOGCFeatureGraphicOrigin");var m;class v extends h.A{get[(m=g,y.ym)](){return this.layer}get[d.e](){return this.layer}get[f.Q](){return this.layer}constructor(e){super(),this[m]=!0,this.type="ogc-feature",this.layer=e}get id(){return this.layer.id}}var w=r(4146),C=r(92474),M=r(799),I=r(75321),x=r(4071),S=r(22671);let A=class extends C.x_{constructor(){super(...arguments),this.featureDefinition=null,this.type="ogc-feature"}load(e){return this.addResolvingPromise(this._loadOGCServices(this.layer,e)),this.when()}getSource(){const{featureDefinition:{collection:e,layerDefinition:t,spatialReference:r,supportedCrs:n},layer:{apiKey:i,customParameters:s,effectiveMaxRecordCount:o}}=this;return{type:"ogc-source",collection:e,layerDefinition:t,maxRecordCount:o,queryParameters:{apiKey:i,customParameters:s},spatialReference:r,supportedCrs:n}}queryExtent(e,t={}){return null}queryFeatureCount(e,t={}){return null}queryFeatures(e,t={}){return this.queryFeaturesJSON(e,t).then(e=>S.A.fromJSON(e))}queryFeaturesJSON(e,t={}){const r=this.getSource();return this.load(t).then(()=>(0,I.bW)(r,e,t))}queryObjectIds(e,t={}){return null}serviceSupportsSpatialReference(e){const{isWebMercator:t,isWGS84:r,latestWkid:n,wkid:i}=e,{supportedCrs:s}=this.featureDefinition;return r||t||!!i&&!!s[i]||!!n&&!!s[n]}_conformsToType(e,t){const r=new RegExp(`^${(0,M.Cj)(t)}$`,"i");return e.conformsTo.some(e=>r.test(e))??!1}_getCapabilities(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:!1,supportsDelete:!1,supportsEditing:!1,supportsChangeTracking:!1,supportsQuery:!1,supportsQueryBins:!1,supportsQueryPivot:!1,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:{maxRecordCount:t,maxRecordCountFactor:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,supportsCacheHint:!1,supportsCentroid:!1,supportsCentroidOnDegeneratedQuantizedGeometry:!1,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPaginationOnAggregatedQueries:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsReturnMesh:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsStatistics:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,supportsSqlExpression:!1,supportsTrueCurve:!1,tileMaxRecordCount:void 0},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},queryAttributeBins:x.$,editing:{supportsDeleteByAnonymous:!1,supportsDeleteByOthers:!1,supportsGeometryUpdate:!1,supportsGlobalId:!1,supportsReturnServiceEditsInSourceSpatialReference:!1,supportsRollbackOnFailure:!1,supportsUpdateByAnonymous:!1,supportsUpdateByOthers:!1,supportsUploadWithItemId:!1,supportsUpdateWithoutM:!1,supportsAsyncApplyEdits:!1,zDefault:void 0}}}_getMaxRecordCount(e){const t=e?.components?.parameters;return t?.limit?.schema?.maximum??t?.limitFeatures?.schema?.maximum}_getStorageSpatialReference(e){const t=e.storageCrs??I.QE,r=(0,I.J0)(t);return null==r?p.A.WGS84:new p.A({wkid:r})}_getSupportedSpatialReferences(e,t){const r="#/crs",n=e.crs??[I.QE],i=n.includes(r)?n.filter(e=>e!==r).concat(t.crs??[]):n,s=/^http:\/\/www\.opengis.net\/def\/crs\/epsg\/.*\/3785$/i;return i.filter(e=>!s.test(e))}async _loadOGCServices(e,t){const r=null!=t?t.signal:null,{apiKey:n,collectionId:i,customParameters:o,fields:l,geometryType:a,hasZ:u,objectIdField:p,timeInfo:d,url:y}=e,f={fields:l?.map(e=>e.toJSON()),geometryType:c.Ye.toJSON(a),hasZ:u,objectIdField:p,timeInfo:d?.toJSON()},h={apiKey:n,customParameters:o,signal:r},g=await(0,I.Ki)(y,h),[m,v]=await Promise.all([(0,I.Px)(g,h),(0,I.bV)(g,h)]);if(!this._conformsToType(m,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/geojson"))throw new s.A("ogc-feature-layer:no-geojson-support","Server does not support geojson");const w=v.collections.find(({id:e})=>e===i);if(!w)throw new s.A("ogc-feature-layer:collection-not-found","Server does not contain the named collection");const C=this._conformsToType(m,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/oas30")?await(0,I.GA)(g,h):null,x=await(0,I.GL)(w,f,h),S=this._getMaxRecordCount(C),A=this._getCapabilities(x.hasZ,S),T=this._getStorageSpatialReference(w).toJSON(),R=this._getSupportedSpatialReferences(w,v),O=new RegExp(`^${(0,M.Cj)(I.vJ)}`,"i"),P={};for(const e of R){const t=(0,I.J0)(e);null!=t&&(P[t]||(P[t]=e.replace(O,"")))}this.featureDefinition={capabilities:A,collection:w,layerDefinition:x,spatialReference:T,supportedCrs:P}}};(0,n.Cg)([(0,l.MZ)()],A.prototype,"featureDefinition",void 0),(0,n.Cg)([(0,l.MZ)({constructOnly:!0})],A.prototype,"layer",void 0),(0,n.Cg)([(0,l.MZ)()],A.prototype,"type",void 0),A=(0,n.Cg)([(0,a.$)("esri.layers.graphics.sources.OGCFeatureSource")],A);var T=r(52136),R=r(63074),O=r(69208),P=r(6455),F=r(87718),b=r(56658),Z=r(16131),j=r(32756),E=r(8303),D=r(54310),U=r(25036),G=r(82935),_=r(63396),L=r(10873),N=r(33143),k=r(20437),B=r(17036),$=r(30524),z=r(46499),q=r(39383),Q=r(41214),H=r(61956),J=r(30291);const K=(0,B.p)();let W=class extends((0,P.FJ)((0,T.p)((0,O.d)((0,b.J)((0,F.F)((0,R.dM)((0,j.fY)((0,G.e)((0,_.d)((0,U.j)((0,Z.q)((0,E.A)((0,D.J)((0,o.P)(w.A))))))))))))))){constructor(e){super(e),this.capabilities=null,this.collectionId=null,this.copyright=null,this.description=null,this.displayField=null,this.elevationInfo=null,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,this.graphicOrigin=new v(this),this.hasZ=void 0,this.labelingInfo=null,this.labelsVisible=!0,this.legendEnabled=!0,this.maxRecordCount=null,this.objectIdField=null,this.operationalLayerType="OGCFeatureLayer",this.popupEnabled=!0,this.popupTemplate=null,this.screenSizePerspectiveEnabled=!0,this.source=new A({layer:this}),this.spatialReference=null,this.title=null,this.type="ogc-feature",this.typeIdField=null,this.types=null,this.url=null}destroy(){this.source?.destroy()}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["OGCFeatureServer"]},e).then(()=>this._fetchService(e))),this.when()}get defaultPopupTemplate(){return this.createPopupTemplate()}get effectiveMaxRecordCount(){return this.maxRecordCount??this.capabilities?.query.maxRecordCount??5e3}get isTable(){return this.loaded&&null==this.geometryType}set renderer(e){(0,$.yp)(e,this.fieldsIndex),this._set("renderer",e)}createPopupTemplate(e){return(0,J.tn)(this,e)}createQuery(){return new H.A}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e,t){let r,n=!1;const i=t?.feature?.attributes,s=this.typeIdField&&i?.[this.typeIdField];return null!=s&&this.types&&(n=this.types.some(t=>t.id==s&&(r=t.domains?.[e],"inherited"===r?.type&&(r=this._getLayerDomain(e)),!0))),n||r||(r=this._getLayerDomain(e)),r}queryFeatures(e,t){return this.load().then(()=>this.source.queryFeatures(H.A.from(e)||this.createQuery(),t)).then(e=>(e?.features?.forEach(e=>{e.layer=e.sourceLayer=this,e.origin=this.graphicOrigin}),e))}async queryAttributeBins(e,t){throw new s.A("OGCFeatureLayer","Layer source does not support queryAttributeBins capability")}serviceSupportsSpatialReference(e){return this.source?.serviceSupportsSpatialReference(e)??!1}async _fetchService(e){await this.source.load(e),this.read(this.source.featureDefinition,{origin:"service"}),(0,$.yp)(this.renderer,this.fieldsIndex),(0,$.sv)(this.timeInfo,this.fieldsIndex)}_getLayerDomain(e){if(!this.fields)return null;for(const t of this.fields)if(t.name===e&&t.domain)return t.domain;return null}};(0,n.Cg)([(0,l.MZ)({readOnly:!0,json:{origins:{service:{read:!0}}}})],W.prototype,"capabilities",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],W.prototype,"collectionId",void 0),(0,n.Cg)([(0,l.MZ)({type:String})],W.prototype,"copyright",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0})],W.prototype,"defaultPopupTemplate",null),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:String,json:{origins:{service:{name:"collection.description"}}}})],W.prototype,"description",void 0),(0,n.Cg)([(0,l.MZ)({type:String})],W.prototype,"displayField",void 0),(0,n.Cg)([(0,l.MZ)({type:Number})],W.prototype,"effectiveMaxRecordCount",null),(0,n.Cg)([(0,l.MZ)(L.Yj)],W.prototype,"elevationInfo",void 0),(0,n.Cg)([(0,l.MZ)({type:[k.A],json:{origins:{service:{name:"layerDefinition.fields"}}}})],W.prototype,"fields",void 0),(0,n.Cg)([(0,l.MZ)(K.fieldsIndex)],W.prototype,"fieldsIndex",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:u.A,json:{origins:{service:{name:"layerDefinition.extent"}}}})],W.prototype,"fullExtent",void 0),(0,n.Cg)([(0,l.MZ)({type:c.gy.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:c.gy.read}}}}})],W.prototype,"geometryType",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,clonable:!1})],W.prototype,"graphicOrigin",void 0),(0,n.Cg)([(0,l.MZ)({type:Boolean,json:{origins:{service:{name:"layerDefinition.hasZ"}}}})],W.prototype,"hasZ",void 0),(0,n.Cg)([(0,l.MZ)({type:Boolean,readOnly:!0})],W.prototype,"isTable",null),(0,n.Cg)([(0,l.MZ)({type:[z.A],json:{origins:{"web-document":{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:q.w},write:!0}}}})],W.prototype,"labelingInfo",void 0),(0,n.Cg)([(0,l.MZ)(L.kF)],W.prototype,"labelsVisible",void 0),(0,n.Cg)([(0,l.MZ)(L.fV)],W.prototype,"legendEnabled",void 0),(0,n.Cg)([(0,l.MZ)({type:Number})],W.prototype,"maxRecordCount",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{origins:{service:{name:"layerDefinition.objectIdField"}}}})],W.prototype,"objectIdField",void 0),(0,n.Cg)([(0,l.MZ)({type:["OGCFeatureLayer"]})],W.prototype,"operationalLayerType",void 0),(0,n.Cg)([(0,l.MZ)(L.M6)],W.prototype,"popupEnabled",void 0),(0,n.Cg)([(0,l.MZ)({type:i.A,json:{name:"popupInfo",write:!0}})],W.prototype,"popupTemplate",void 0),(0,n.Cg)([(0,l.MZ)({types:Q.Hg,json:{origins:{service:{name:"layerDefinition.drawingInfo.renderer",write:!1},"web-scene":{types:Q.XJ,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:!0}})],W.prototype,"renderer",null),(0,n.Cg)([(0,l.MZ)(L.PY)],W.prototype,"screenSizePerspectiveEnabled",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0})],W.prototype,"source",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,type:p.A,json:{origins:{service:{read:!0}}}})],W.prototype,"spatialReference",void 0),(0,n.Cg)([(0,l.MZ)({type:String,json:{write:{enabled:!0,ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"collection.title"}}}})],W.prototype,"title",void 0),(0,n.Cg)([(0,l.MZ)({readOnly:!0,json:{read:!1}})],W.prototype,"type",void 0),(0,n.Cg)([(0,l.MZ)({type:String,readOnly:!0})],W.prototype,"typeIdField",void 0),(0,n.Cg)([(0,l.MZ)({type:[N.A]})],W.prototype,"types",void 0),(0,n.Cg)([(0,l.MZ)(L.OZ)],W.prototype,"url",void 0),W=(0,n.Cg)([(0,a.$)("esri.layers.OGCFeatureLayer")],W);const V=W},69208:(e,t,r)=>{r.d(t,{d:()=>o});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(64108));const o=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.customParameters=null}};return(0,n.Cg)([(0,i.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],r.prototype,"customParameters",void 0),r=(0,n.Cg)([(0,s.$)("esri.layers.mixins.CustomParametersMixin")],r),r}},73133:(e,t,r)=>{r.d(t,{j:()=>n});const n=(0,r(66552).O)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},82935:(e,t,r)=>{r.d(t,{B:()=>y,e:()=>f});var n=r(31635),i=r(10107),s=(r(44208),r(53966),r(87811),r(36005)),o=r(64108),l=r(89317),a=r(30524),u=r(96184),p=r(73133),c=r(79677),d=r(10184);const y={type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation",layerContainerTypes:l.K}}},f=e=>{const t=e;let r=class extends t{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const n=r.timeOffset,i=p.j.fromJSON(r.timeOffsetUnits);return n&&i?new d.A({value:n,unit:i}):null}set timeInfo(e){(0,a.sv)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n.Cg)([(0,i.MZ)({type:c.A,json:{write:!1}})],r.prototype,"timeExtent",void 0),(0,n.Cg)([(0,i.MZ)({type:d.A})],r.prototype,"timeOffset",void 0),(0,n.Cg)([(0,s.w)("service","timeOffset",["timeInfo.exportOptions"])],r.prototype,"readOffset",null),(0,n.Cg)([(0,i.MZ)({value:null,type:u.A,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],r.prototype,"timeInfo",null),(0,n.Cg)([(0,i.MZ)(y)],r.prototype,"useViewTime",void 0),r=(0,n.Cg)([(0,o.$)("esri.layers.mixins.TemporalLayer")],r),r}},83960:(e,t,r)=>{r.d(t,{X_:()=>o,oW:()=>a,zx:()=>l});var n=r(34727),i=r(83047);const s=96;function o(e,t){const r=t||e.extent,n=e.width,o=(0,i.GA)(r?.spatialReference);return r&&n?r.width/n*o*i.dy*s:0}function l(e,t,r){return function(e,t){return 0===t||(0,n.Sp)(e,t)||e<t}(e,t)&&function(e,t){return 0===t||(0,n.Sp)(e,t)||e>t}(e,r)}function a(e,t){return(0,n.Sp)(e,t)?0:(e||Number.POSITIVE_INFINITY)>(t||Number.POSITIVE_INFINITY)?1:-1}},91218:(e,t,r)=>{r.r(t),r.d(t,{canProjectWithoutEngine:()=>z,initializeProjection:()=>Q,isEqualBaseGCS:()=>q,isLoaded:()=>F,isLoadedOrLoad:()=>b,isLoadedOrLoadFor:()=>Z,load:()=>E,project:()=>D,projectExtent:()=>re,projectMany:()=>U,projectMultipoint:()=>W,projectOrLoad:()=>G,projectOrLoadMany:()=>_,projectPoint:()=>J,projectPolygon:()=>ee,projectPolyline:()=>Y,projectWithZConversion:()=>$,projectWithoutEngine:()=>H,requiresLoad:()=>j,test:()=>k,tryProjectWithZConversion:()=>B,unload:()=>N});var n=r(49186),i=r(74887),s=r(62788),o=r(95488),l=r(51850),a=r(21276),u=r(73941),p=r(5443),c=r(91075),d=r(48526),y=r(86738),f=r(39829),h=r(82799),g=r(16930),m=r(159),v=r(9762),w=r(37539);function C(e,t,r,n,i,s){return M[0]=e,M[1]=t,M[2]=r,(0,v.projectBuffer)(M,n,0,i,s,0)}const M=(0,l.vt)();var I=r(21325),x=r(62815);let S=null,A=null,T=null,R=null,O={};const P=new o.I;function F(){return!!(A?.isLoaded()&&T?.isLoaded()&&R?.isLoaded())}function b(){return!!F()||((0,s.gc)(P),E(),!1)}function Z(e,t){return!e||!t||z(e,t)||b()}function j(e,t){return!z(e,t)&&!F()}async function E(e){null==S&&(S=Promise.all([r.e(3276).then(r.bind(r,83276)).then(e=>(A=e,A.load())),r.e(8377).then(r.bind(r,8377)).then(e=>(T=e,T.load())),r.e(2158).then(r.bind(r,12158)).then(e=>(R=e,R.load()))])),await S,(0,i.Te)(e),P.notify()}function D(e,t,r){return Array.isArray(e)?0===e.length?[]:((0,a.H)(e),U(e,e[0].spatialReference,t,r)):((0,a.f)(e),U([e],e.spatialReference,t,r)[0])}function U(e,t,r,n){if(null==t||null==r)return e;if(z(t,r,n))return e.map(e=>H(e,t,r));if(null==n?.geographicTransformation&&(0,u.jA)(t))return e.map(e=>H(e,t,g.A.WGS84)).map(e=>B(e,r));if(null==n?.geographicTransformation&&(0,u.jA)(r))return e.map(e=>B(e,g.A.WGS84)).map(e=>H(e,g.A.WGS84,r));if(!F())throw new L;if(!n?.geographicTransformation)if(n?.extendedParams)n={...n,geographicTransformation:R.getTransformation(t,r,n.areaOfInterestExtent)||new m.A};else if(!n?.areaOfInterestExtent){const e=function(e,t){return[e.wkid?.toString()??"-1",e.wkt?.toString()??"",e.wkt2?.toString()??"",t.wkid?.toString()??"-1",t.wkt?.toString()??"",t.wkt2?.toString()??""].join()}(t,r);let i=O[e];i||(i=R.getTransformation(t,r)||new m.A,O[e]=i),n={geographicTransformation:i}}return e[0].spatialReference||(e[0].spatialReference=t),e[0]instanceof c.A?A.executeMany(e,r,n):T.executeMany(e,r,n)}function G(e,t){const r=_([e],t);return null!=r.pending?{pending:r.pending,geometry:null}:null!=r.geometries?{pending:null,geometry:r.geometries[0]}:{pending:null,geometry:null}}function _(e,t){if(!F())for(const r of e)if(null!=r&&!(0,I.aI)(r.spatialReference,t)&&(0,I.fn)(r.spatialReference)&&(0,I.fn)(t)&&!z(r.spatialReference,t))return(0,s.gc)(P),{pending:E(),geometries:null};return{pending:null,geometries:e.map(e=>null==e?null:(0,I.aI)(e.spatialReference,t)?e:(0,I.fn)(e.spatialReference)&&(0,I.fn)(t)?B(e,t):null)}}class L extends n.A{constructor(){super("projection:not-loaded","projection engine not fully loaded yet, please call load()")}}function N(){S=null,A=null,T=null,R=null,O={}}const k={get loadPromise(){return S}};function B(e,t){try{const r=D(e,t);if(null==r)return null;"xmin"in e&&"xmin"in r&&(r.zmin=e.zmin,r.zmax=e.zmax);const n=(0,x.N)(r.type,e.spatialReference,t);return null!=n&&n(r),r}catch(e){if(!(e instanceof L))throw e;return null}}async function $(e,t,r){const n=e.spatialReference;return null!=n&&null!=t&&await Q(n,t,null,r),B(e,t)}function z(e,t,r){return!(r?.areaOfInterestExtent||r?.extendedParams||r?.geographicTransformation)&&(!!(0,I.aI)(e,t)||(0,I.fn)(e)&&(0,I.fn)(t)&&!!(0,w.jd)(e,t))}function q(e,t){if((0,I.aI)(e,t))return!0;if(!(0,I.fn)(e)||!(0,I.fn)(t))return!1;const r=(0,I.oT)(e)||(0,I.K8)(e)||(0,I.x1)(e),n=(0,I.oT)(t)||(0,I.K8)(t)||(0,I.x1)(t);return r&&n}async function Q(e,t,r,n){if(F())return(0,i.NO)(n);if(Array.isArray(e)){for(const{source:t,dest:r,options:i}of e)if(t&&r&&!z(t,r,i))return E(n)}else if(e&&t&&!z(e,t,r))return E(n);return(0,i.NO)(n)}function H(e,t,r){return e?"x"in e?K(e,t,new y.A,r,0):"xmin"in e?ne(e,t,new p.A,r,0):"rings"in e?te(e,t,new f.A,r,0):"paths"in e?X(e,t,new h.A,r,0):"points"in e?V(e,t,new d.A,r,0):null:null}function J(e,t,r=t.spatialReference,n=0){return null!=r&&null!=e.spatialReference&&null!=K(e,e.spatialReference,t,r,n)}function K(e,t,r,n,i){se[0]=e.x,se[1]=e.y;const s=e.z;return se[2]=void 0!==s?s:i,(0,v.projectBuffer)(se,t,0,se,n,0)?(r.x=se[0],r.y=se[1],r.spatialReference=n,void 0!==s||(0,u.xP)(n)?(r.z=se[2],r.hasZ=!0):(r.z=void 0,r.hasZ=!1),void 0===e.m?(r.m=void 0,r.hasM=!1):(r.m=e.m,r.hasM=!0),r):null}function W(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=V(e,e.spatialReference,t,r,n)}function V(e,t,r,n,i){const{points:s,hasZ:o,hasM:l}=e,a=[],p=s.length,c=[];for(const e of s)c.push(e[0],e[1],o?e[2]:i);if(!(0,v.projectBuffer)(c,t,0,c,n,0,p))return null;const d=o||(0,u.xP)(n);for(let e=0;e<p;++e){const t=3*e,r=c[t],n=c[t+1];d&&l?a.push([r,n,c[t+2],s[e][3]]):d?a.push([r,n,c[t+2]]):l?a.push([r,n,s[e][2]]):a.push([r,n])}return r.points=a,r.spatialReference=n,r.hasZ=o,r.hasM=l,r}function Y(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=X(e,e.spatialReference,t,r,n)}function X(e,t,r,n,i){const{paths:s,hasZ:o,hasM:l}=e,a=[];if(!ie(s,o??!1,l??!1,t,a,n,i))return null;const p=o||(0,u.xP)(n);return r.paths=a,r.spatialReference=n,r.hasZ=p,r.hasM=l,r}function ee(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=te(e,e.spatialReference,t,r,n)}function te(e,t,r,n,i){const{rings:s,hasZ:o,hasM:l}=e,a=[];if(!ie(s,o??!1,l??!1,t,a,n,i))return null;const p=o||(0,u.xP)(n);return r.rings=a,r.spatialReference=n,r.hasZ=p,r.hasM=l,r}function re(e,t,r=t.spatialReference,n=0){return null!=e.spatialReference&&null!=r&&null!=ne(e,e.spatialReference,t,r,n)}function ne(e,t,r,n,i){const{xmin:s,ymin:o,xmax:l,ymax:a,hasZ:p,hasM:c}=e;if(!C(s,o,p?e.zmin:i,t,se,n))return null;const d=p||(0,u.xP)(n);return r.xmin=se[0],r.ymin=se[1],d&&(r.zmin=se[2]),C(l,a,p?e.zmax:i,t,se,n)?(r.xmax=se[0],r.ymax=se[1],d&&(r.zmax=se[2]),c&&(r.mmin=e.mmin,r.mmax=e.mmax),r.spatialReference=n,r):null}function ie(e,t,r,n,i,s,o=0){const l=new Array;for(const r of e)for(const e of r)l.push(e[0],e[1],t?e[2]:o);if(!(0,v.projectBuffer)(l,n,0,l,s,0))return!1;let a=0;i.length=0;const p=t||(0,u.xP)(s);for(const t of e){const e=new Array;for(const n of t)p&&r?e.push([l[a++],l[a++],l[a++],n[3]]):p?e.push([l[a++],l[a++],l[a++]]):r?(e.push([l[a++],l[a++],n[2]]),a++):(e.push([l[a++],l[a++]]),a++);i.push(e)}return!0}const se=(0,l.vt)()},91880:(e,t,r)=>{r.d(t,{A:()=>p});var n,i=r(31635),s=r(66552),o=r(25482),l=r(10107),a=(r(44208),r(53966),r(87811),r(64108));const u=new s.J({asc:"ascending",desc:"descending"});let p=class extends o.o{static{n=this}constructor(e){super(e),this.field=null,this.valueExpression=null,this.order="ascending"}clone(){return new n({field:this.field,valueExpression:this.valueExpression,order:this.order})}};(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],p.prototype,"field",void 0),(0,i.Cg)([(0,l.MZ)({type:String,json:{write:!0,origins:{"web-scene":{read:!1,write:!1}}}})],p.prototype,"valueExpression",void 0),(0,i.Cg)([(0,l.MZ)({type:u.apiValues,json:{type:u.jsonValues,read:u.read,write:u.write}})],p.prototype,"order",void 0),p=n=(0,i.Cg)([(0,a.$)("esri.layers.support.OrderByInfo")],p)},96184:(e,t,r)=>{r.d(t,{A:()=>f});var n=r(31635),i=r(69540),s=r(25482),o=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),a=r(64108),u=r(43937),p=r(79677),c=r(10184),d=r(56400);function y(e,t){return c.A.fromJSON({value:e,unit:t})}let f=class extends((0,i.OU)(s.o)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0,this.stops=null}readFullTimeExtent(e,t){return t.timeExtent&&Array.isArray(t.timeExtent)&&2===t.timeExtent.length?p.A.fromArray(t.timeExtent):null}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=e.toArray():t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?y(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?y(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],f.prototype,"cumulative",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"endField",void 0),(0,n.Cg)([(0,o.MZ)({type:p.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"fullTimeExtent",void 0),(0,n.Cg)([(0,l.w)("fullTimeExtent",["timeExtent"])],f.prototype,"readFullTimeExtent",null),(0,n.Cg)([(0,u.K)("fullTimeExtent")],f.prototype,"writeFullTimeExtent",null),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{write:!0}})],f.prototype,"hasLiveData",void 0),(0,n.Cg)([(0,o.MZ)({type:c.A,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"interval",void 0),(0,n.Cg)([(0,l.w)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],f.prototype,"readInterval",null),(0,n.Cg)([(0,u.K)("interval")],f.prototype,"writeInterval",null),(0,n.Cg)([(0,o.MZ)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"startField",void 0),(0,n.Cg)([(0,o.MZ)((0,d.P6)("timeReference",!0))],f.prototype,"timeZone",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"trackIdField",void 0),(0,n.Cg)([(0,o.MZ)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],f.prototype,"useTime",void 0),(0,n.Cg)([(0,o.MZ)({type:[Date],json:{read:!1}})],f.prototype,"stops",void 0),f=(0,n.Cg)([(0,a.$)("esri.layers.support.TimeInfo")],f)},99157:(e,t,r)=>{r.d(t,{A:()=>a});var n,i=r(31635),s=r(69622),o=r(10107),l=(r(44208),r(53966),r(87811),r(64108));let a=n=class extends s.A{constructor(e){super(e),this.isInverse=!1,this.wkt=null,this.wkid=null}getInverse(){return new n({isInverse:!this.isInverse,wkid:this.wkid,wkt:this.wkt})}};(0,i.Cg)([(0,o.MZ)()],a.prototype,"isInverse",void 0),(0,i.Cg)([(0,o.MZ)()],a.prototype,"wkt",void 0),(0,i.Cg)([(0,o.MZ)()],a.prototype,"wkid",void 0),a=n=(0,i.Cg)([(0,l.$)("esri.geometry.operators.support.GeographicTransformationStep")],a)},99352:(e,t,r)=>{r.d(t,{F:()=>n,P:()=>i});const n={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCentroidOnDegeneratedQuantizedGeometry:!0,supportsCacheHint:!0,supportsCurrentUser:!1,supportsDegeneratedQuantizedGeometry:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsPaginationOnAggregatedQueries:!1,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!0,supportsReturnMesh:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,maxUniqueIDCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0,supportsTrueCurve:!1},i={supportsDate:!0,supportsFixedInterval:!0,supportsAutoInterval:!0,supportsFixedBoundaries:!0,supportsStackBy:!0,supportsSplitBy:!0,supportsSnapToData:!1,supportsReturnFullIntervalBin:!1,supportsFirstDayOfWeek:!1,supportsNormalization:!0,supportedStatistics:{count:!0,sum:!0,avg:!0,var:!0,stddev:!0,min:!0,max:!0,percentileContinuous:!0,percentileDiscrete:!0,envelope:!0,centroid:!0,convexHull:!0},supportedNormalizationTypes:{field:!0,log:!0,naturalLog:!0,percentOfTotal:!0,squareRoot:!0}}}}]);