@arcgis/core 4.28.3 → 4.28.5
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.
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{15852a47129b9e0d04c6.js → 023fc8504d032762ad82.js} +1 -1
- package/assets/esri/core/workers/chunks/{80d9bb9f247ecdfa266f.js → 0695fcdc01f195c5ae8d.js} +1 -1
- package/assets/esri/core/workers/chunks/{4363f2cc3909c9258064.js → 076ac767b5148357f1b5.js} +1 -1
- package/assets/esri/core/workers/chunks/07cb7d142205f2eccc83.js +1 -0
- package/assets/esri/core/workers/chunks/0f6b766f08c648fd7b99.js +1 -0
- package/assets/esri/core/workers/chunks/16b56e541afa438dfb7f.js +1 -0
- package/assets/esri/core/workers/chunks/1c855f091d1305b82594.js +1 -0
- package/assets/esri/core/workers/chunks/28c4a21cdddf2602ab97.js +1 -0
- package/assets/esri/core/workers/chunks/2cf2340ad817f3c27802.js +1 -0
- package/assets/esri/core/workers/chunks/319c222ce72254934060.js +1 -0
- package/assets/esri/core/workers/chunks/340ab726ba40fe3a99c8.js +1 -0
- package/assets/esri/core/workers/chunks/46b4a17ec898ab744861.js +1 -0
- package/assets/esri/core/workers/chunks/4a5d0b49a641d182b5ea.js +1 -0
- package/assets/esri/core/workers/chunks/{7f3bc7a2de59e485f22f.js → 4f0412b52844aa9c7bd4.js} +1 -1
- package/assets/esri/core/workers/chunks/54867a094fb740a6f4d9.js +1 -0
- package/assets/esri/core/workers/chunks/5b80ae1eb79f1db75dc6.js +1 -0
- package/assets/esri/core/workers/chunks/80fcb63476829b6a48d2.js +1 -0
- package/assets/esri/core/workers/chunks/84725021c43f1122056a.js +1 -0
- package/assets/esri/core/workers/chunks/{9f0e8dd5c9bacfc0f03c.js → 908a5326b61843d6d2b3.js} +1 -1
- package/assets/esri/core/workers/chunks/9607460895182d31aef9.js +1 -0
- package/assets/esri/core/workers/chunks/9ef3746c545296565ef6.js +1 -0
- package/assets/esri/core/workers/chunks/{77f557359a5033d7e429.js → a0a86383e69932a25e50.js} +1 -1
- package/assets/esri/core/workers/chunks/a3bf50d9e24ad1de9847.js +1 -0
- package/assets/esri/core/workers/chunks/a5db3be5eeb3005df3c1.js +1 -0
- package/assets/esri/core/workers/chunks/a87ab14d6a6ccc9004a0.js +1 -0
- package/assets/esri/core/workers/chunks/af13150c711ba7b7f3ac.js +1 -0
- package/assets/esri/core/workers/chunks/ba00df2e707550939a6f.js +1 -0
- package/assets/esri/core/workers/chunks/ca43955065012d4b22e9.js +1 -0
- package/assets/esri/core/workers/chunks/cfa6d1b63b794febe70a.js +1 -0
- package/assets/esri/core/workers/chunks/e0382138cf58191a9697.js +1 -0
- package/assets/esri/core/workers/chunks/e076c5523dfb6c53a825.js +1 -0
- package/assets/esri/core/workers/chunks/{e3950975030412ff6e20.js → f343db8dad71f3840610.js} +1 -1
- package/assets/esri/core/workers/chunks/{46ddc52fe9cdd573a614.js → fa5c69a0cdd78aa34ad7.js} +1 -1
- package/assets/esri/core/workers/chunks/fe0c6814ef56604540b3.js +1 -0
- package/core/date.js +1 -1
- package/core/sql/WhereClause.js +1 -1
- package/kernel.js +1 -1
- package/layers/graphics/data/QueryEngineResult.js +1 -1
- package/layers/graphics/sources/geojson/geojson.js +1 -1
- package/layers/save/featureLayerUtils.js +1 -1
- package/layers/support/fetchService.js +1 -1
- package/layers/support/vectorTileLayerLoader.js +1 -1
- package/package.json +1 -1
- package/support/revision.js +1 -1
- package/views/2d/engine/webgl/Painter.js +1 -1
- package/views/2d/layers/features/sources/DataTileSubscription.js +1 -1
- package/views/3d/layers/graphics/elevationAlignPointsInFeatures.js +1 -1
- package/views/PopupView.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
- package/views/interactive/snapping/featureSources/snappingCandidateElevationAlignment.js +1 -1
- package/widgets/FeatureForm/FieldInput.js +1 -1
- package/widgets/FeatureForm/featureFormUtils.js +1 -1
- package/widgets/FeatureForm.js +1 -1
- package/widgets/Features.js +1 -1
- package/widgets/Legend/LegendViewModel.js +1 -1
- package/widgets/Popup.js +1 -1
- package/assets/esri/core/workers/chunks/32fbd4355a4a649623a7.js +0 -1
- package/assets/esri/core/workers/chunks/41306b698f78001dda55.js +0 -1
- package/assets/esri/core/workers/chunks/423672fe765083e1a0ec.js +0 -1
- package/assets/esri/core/workers/chunks/49d958631bcd93f6333a.js +0 -1
- package/assets/esri/core/workers/chunks/49faa024bab1ba6e2bf0.js +0 -1
- package/assets/esri/core/workers/chunks/534726130ef1698ec89e.js +0 -1
- package/assets/esri/core/workers/chunks/7beae29abdfae23b15cc.js +0 -1
- package/assets/esri/core/workers/chunks/846e5e51dc278bc3f80f.js +0 -1
- package/assets/esri/core/workers/chunks/8b541cbf82a5ba0317ee.js +0 -1
- package/assets/esri/core/workers/chunks/8e91be2e38010391e351.js +0 -1
- package/assets/esri/core/workers/chunks/90f96a2ddfb25d851d4d.js +0 -1
- package/assets/esri/core/workers/chunks/91a3181071874525ed44.js +0 -1
- package/assets/esri/core/workers/chunks/97fd7b82eec26449977e.js +0 -1
- package/assets/esri/core/workers/chunks/9d97a20f69047d0c47cc.js +0 -1
- package/assets/esri/core/workers/chunks/ac4636e82a103e2c27ca.js +0 -1
- package/assets/esri/core/workers/chunks/ae7ba94af6d4fd97dd8b.js +0 -1
- package/assets/esri/core/workers/chunks/b0653f63745e756f55fe.js +0 -1
- package/assets/esri/core/workers/chunks/c2199fb8f7a54a0ef18a.js +0 -1
- package/assets/esri/core/workers/chunks/c3f462d11ed570482e7a.js +0 -1
- package/assets/esri/core/workers/chunks/c8cb5fe1d23145c4842b.js +0 -1
- package/assets/esri/core/workers/chunks/ce409944221a784ddb61.js +0 -1
- package/assets/esri/core/workers/chunks/e8b7d1c586aff229484c.js +0 -1
- package/assets/esri/core/workers/chunks/eb5213ffb83d83a4dd05.js +0 -1
- package/assets/esri/core/workers/chunks/f037e4f9877ea08ced9d.js +0 -1
- package/assets/esri/core/workers/chunks/f520f093aa81d8ee1790.js +0 -1
- package/assets/esri/core/workers/chunks/f7ccc6c681fc9218555c.js +0 -1
- package/assets/esri/core/workers/chunks/fab4ee57b7c5376c9ccd.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8062,8008],{7335:(e,a,r)=>{r.d(a,{L:()=>n});var t=r(96187);class n{constructor(){this._serviceMetadatas=new Map}async fetchServiceMetadata(e,a){const r=this._serviceMetadatas.get(e);if(r)return r;const n=await(0,t.T)(e,a);return this._serviceMetadatas.set(e,n),n}}},71592:(e,a,r)=>{r.d(a,{w:()=>y});var t=r(40330),n=r(3172),i=r(20102),l=r(95330),s=r(66677),o=r(48522),c=r(15235);async function y(e,a){const r=(0,s.Qc)(e);if(!r)throw new i.Z("invalid-url","Invalid scene service url");const y={...a,sceneServerUrl:r.url.path,layerId:r.sublayer??void 0};if(y.sceneLayerItem??=await async function(e){const a=(await u(e)).serviceItemId;if(!a)return null;const r=new c.default({id:a,apiKey:e.apiKey}),i=await async function(e){const a=t.id?.findServerInfo(e.sceneServerUrl);if(a?.owningSystemUrl)return a.owningSystemUrl;const r=e.sceneServerUrl.replace(/(.*\/rest)\/.*/i,"$1")+"/info";try{const a=(await(0,n.Z)(r,{query:{f:"json"},responseType:"json",signal:e.signal})).data.owningSystemUrl;if(a)return a}catch(e){(0,l.r9)(e)}return null}(e);null!=i&&(r.portal=new o.Z({url:i}));try{return r.load({signal:e.signal})}catch(e){return(0,l.r9)(e),null}}(y),null==y.sceneLayerItem)return d(y.sceneServerUrl.replace("/SceneServer","/FeatureServer"),y);const p=await async function({sceneLayerItem:e,signal:a}){if(!e)return null;try{const r=(await e.fetchRelatedItems({relationshipType:"Service2Service",direction:"reverse"},{signal:a})).find((e=>"Feature Service"===e.type))||null;if(!r)return null;const t=new c.default({portal:r.portal,id:r.id});return await t.load(),t}catch(e){return(0,l.r9)(e),null}}(y);if(!p?.url)throw new i.Z("related-service-not-found","Could not find feature service through portal item relationship");const f=await d(p.url,y);return f.portalItem=p,f}async function u(e){if(e.rootDocument)return e.rootDocument;const a={query:{f:"json",token:e.apiKey},responseType:"json",signal:e.signal};try{const r=await(0,n.Z)(e.sceneServerUrl,a);e.rootDocument=r.data}catch{e.rootDocument={}}return e.rootDocument}async function d(e,a){const r=(0,s.Qc)(e);if(!r)throw new i.Z("invalid-feature-service-url","Invalid feature service url");const t=r.url.path,l=a.layerId;if(null==l)return{serverUrl:t};const o=u(a),c=e=>{const r={query:{f:"json"},responseType:"json",authMode:e,signal:a.signal};return(0,n.Z)(t,r)},y=c("anonymous").catch((()=>c("no-prompt"))),[d,p]=await Promise.all([y,o]),f=p?.layers,L=d.data&&d.data.layers;if(!Array.isArray(L))throw new Error("expected layers array");if(Array.isArray(f)){for(let e=0;e<Math.min(f.length,L.length);e++)if(f[e].id===l)return{serverUrl:t,layerId:L[e].id}}else if(null!=l&&l<L.length)return{serverUrl:t,layerId:L[l].id};throw new Error("could not find matching associated sublayer")}},52104:(e,a,r)=>{r.d(a,{V:()=>n});var t=r(96187);async function n(e,a){const r=await(0,t.T)(e,a);y(r),s(r);const n={serviceJSON:r};if((r.currentVersion??0)<10.5)return n;const i=await(0,t.T)(e+"/layers",a);return y(i),s(i),n.layersJSON={layers:i.layers,tables:i.tables},n}function i(e){return"Feature Layer"===e.type||"Oriented Imagery Layer"===e.type}function l(e){return"Table"===e.type}function s(e){e.layers=e.layers?.filter(i),e.tables=e.tables?.filter(l)}function o(e){e.type||="Feature Layer"}function c(e){e.type||="Table"}function y(e){e.layers?.forEach(o),e.tables?.forEach(c)}},70024:(e,a,r)=>{r.d(a,{k:()=>M,populateOperationalLayers:()=>y});var t=r(46791),n=(r(80442),r(7335)),i=r(87344),l=r(15235);function s(e,a){return!(!e.layerType||"ArcGISFeatureLayer"!==e.layerType)&&e.featureCollectionType===a}var o=r(28008),c=r(40555);async function y(e,a,r){if(!a)return;const t=[];for(const e of a)t.push(g(e,r));const n=await Promise.allSettled(t);for(const a of n)"rejected"===a.status||a.value&&e.add(a.value)}const u={ArcGISDimensionLayer:"DimensionLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",PointCloudLayer:"PointCloudLayer",ArcGISSceneServiceLayer:"SceneLayer",IntegratedMeshLayer:"IntegratedMeshLayer",OGCFeatureLayer:"OGCFeatureLayer",BuildingSceneLayer:"BuildingSceneLayer",ArcGISTiledElevationServiceLayer:"ElevationLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",GroupLayer:"GroupLayer",GeoJSON:"GeoJSONLayer",WebTiledLayer:"WebTileLayer",CSV:"CSVLayer",VectorTileLayer:"VectorTileLayer",WFS:"WFSLayer",WMS:"WMSLayer",DefaultTileLayer:"TileLayer",KML:"KMLLayer",RasterDataLayer:"UnsupportedLayer",Voxel:"VoxelLayer",LineOfSightLayer:"LineOfSightLayer"},d={ArcGISTiledElevationServiceLayer:"ElevationLayer",DefaultTileLayer:"ElevationLayer",RasterDataElevationLayer:"UnsupportedLayer"},p={ArcGISFeatureLayer:"FeatureLayer"},f={ArcGISTiledMapServiceLayer:"TileLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",OpenStreetMap:"OpenStreetMapLayer",WebTiledLayer:"WebTileLayer",VectorTileLayer:"VectorTileLayer",ArcGISImageServiceLayer:"UnsupportedLayer",WMS:"UnsupportedLayer",ArcGISMapServiceLayer:"UnsupportedLayer",ArcGISSceneServiceLayer:"SceneLayer",DefaultTileLayer:"TileLayer"},L={ArcGISAnnotationLayer:"UnsupportedLayer",ArcGISDimensionLayer:"UnsupportedLayer",ArcGISFeatureLayer:"FeatureLayer",ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISStreamLayer:"StreamLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",BingMapsAerial:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",CSV:"CSVLayer",DefaultTileLayer:"TileLayer",GeoRSS:"GeoRSSLayer",GeoJSON:"GeoJSONLayer",GroupLayer:"GroupLayer",KML:"KMLLayer",MediaLayer:"MediaLayer",OGCFeatureLayer:"OGCFeatureLayer",OrientedImageryLayer:"OrientedImageryLayer",SubtypeGroupLayer:"SubtypeGroupLayer",VectorTileLayer:"VectorTileLayer",WFS:"WFSLayer",WMS:"WMSLayer",WebTiledLayer:"WebTileLayer"},m={ArcGISFeatureLayer:"FeatureLayer"},w={ArcGISImageServiceLayer:"ImageryLayer",ArcGISImageServiceVectorLayer:"ImageryLayer",ArcGISMapServiceLayer:"MapImageLayer",ArcGISTiledImageServiceLayer:"ImageryTileLayer",ArcGISTiledMapServiceLayer:"TileLayer",OpenStreetMap:"OpenStreetMapLayer",VectorTileLayer:"VectorTileLayer",WebTiledLayer:"WebTileLayer",BingMapsAerial:"BingMapsLayer",BingMapsRoad:"BingMapsLayer",BingMapsHybrid:"BingMapsLayer",WMS:"WMSLayer",DefaultTileLayer:"TileLayer"},S={...L,LinkChartLayer:"LinkChartLayer"},h={...m},I={...w};async function g(e,a){return async function(e,a,r){const t=new e;return t.read(a,r.context),"group"===t.type&&("GroupLayer"===a.layerType?await M(t,a,r):v(a)?function(e,a,r){a.itemId&&(e.portalItem=new l.default({id:a.itemId,portal:r?.portal}),e.when((()=>{const t=t=>{const n=t.layerId;G(t,e,a,n,r);const i=a.featureCollection?.layers?.[n];i&&t.read(i,r)};e.layers?.forEach(t),e.tables?.forEach(t)})))}(t,a,r.context):b(a)&&await async function(e,a,r){const t=i.T.FeatureLayer,n=await t(),l=a.featureCollection,s=l?.showLegend,o=l?.layers?.map(((t,i)=>{const l=new n;l.read(t,r);const o={...r,ignoreDefaults:!0};return G(l,e,a,i,o),null!=s&&l.read({showLegend:s},o),l}));e.layers.addMany(o??[])}(t,a,r.context)),await(0,c.y)(t,r.context),t}(await async function(e,a){const r=a.context,t=T(r);let c=e.layerType||e.type;!c&&a?.defaultLayerType&&(c=a.defaultLayerType);const y=t[c];let u=y?i.T[y]:i.T.UnknownLayer;if(v(e)){const a=r?.portal;if(e.itemId){const r=new l.default({id:e.itemId,portal:a});await r.load();const t=(await(0,o.v)(r,new n.L)).className||"UnknownLayer";u=i.T[t]}}else"ArcGISFeatureLayer"===c?function(e){return s(e,"notes")}(e)||function(e){return s(e,"markup")}(e)?u=i.T.MapNotesLayer:function(e){return s(e,"route")}(e)?u=i.T.RouteLayer:b(e)&&(u=i.T.GroupLayer):e.wmtsInfo?.url&&e.wmtsInfo.layerIdentifier?u=i.T.WMTSLayer:"WFS"===c&&"2.0.0"!==e.wfsInfo?.version&&(u=i.T.UnsupportedLayer);return u()}(e,a),e,a)}function b(e){return"ArcGISFeatureLayer"===e.layerType&&!v(e)&&(e.featureCollection?.layers?.length??0)>1}function v(e){return"Feature Collection"===e.type}function T(e){let a;switch(e.origin){case"web-scene":switch(e.layerContainerType){case"basemap":a=f;break;case"ground":a=d;break;case"tables":a=p;break;default:a=u}break;case"link-chart":switch(e.layerContainerType){case"basemap":a=I;break;case"tables":a=h;break;default:a=S}break;default:switch(e.layerContainerType){case"basemap":a=w;break;case"tables":a=m;break;default:a=L}}return a}async function M(e,a,r){const n=new t.Z,i=y(n,Array.isArray(a.layers)?a.layers:[],r);try{try{if(await i,"group"===e.type)return e.layers.addMany(n),e}catch(a){e.destroy();for(const e of n)e.destroy();throw a}}catch(e){throw e}}function G(e,a,r,t,n){e.read({id:`${a.id}-sublayer-${t}`,visibility:r.visibleLayers?.includes(t)??!0},n)}},87344:(e,a,r)=>{r.d(a,{T:()=>t});const t={BingMapsLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(8153)]).then(r.bind(r,2723))).default,BuildingSceneLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(4723),r.e(9238),r.e(6170),r.e(1767),r.e(2139),r.e(3554)]).then(r.bind(r,30223))).default,CSVLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(4723),r.e(9238),r.e(7587)]).then(r.bind(r,45425))).default,DimensionLayer:async()=>(await Promise.all([r.e(163),r.e(9717)]).then(r.bind(r,40081))).default,ElevationLayer:async()=>(await Promise.all([r.e(163),r.e(9016),r.e(2763)]).then(r.bind(r,65665))).default,FeatureLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(4723),r.e(9238),r.e(447)]).then(r.bind(r,19238))).default,GeoJSONLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(2934)]).then(r.bind(r,23477))).default,GeoRSSLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(6e3)]).then(r.bind(r,3723))).default,GroupLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9059)]).then(r.bind(r,40504))).default,ImageryLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(4599),r.e(6610),r.e(1319),r.e(4608)]).then(r.bind(r,60590))).default,ImageryTileLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(6610),r.e(1319),r.e(4136),r.e(9532)]).then(r.bind(r,74878))).default,IntegratedMeshLayer:async()=>(await Promise.all([r.e(163),r.e(1767),r.e(1537)]).then(r.bind(r,9310))).default,KMLLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(1423),r.e(6413)]).then(r.bind(r,42756))).default,LineOfSightLayer:async()=>(await Promise.all([r.e(163),r.e(4998)]).then(r.bind(r,21786))).default,LinkChartLayer:async()=>(await Promise.all([r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(7215),r.e(8968),r.e(3794),r.e(6939)]).then(r.bind(r,19087))).default,MapImageLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(4599),r.e(9735),r.e(2725),r.e(7374)]).then(r.bind(r,27374))).default,MapNotesLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(4723),r.e(9238),r.e(6618)]).then(r.bind(r,62128))).default,MediaLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(4828)]).then(r.bind(r,57765))).default,OGCFeatureLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(3966),r.e(2118)]).then(r.bind(r,88068))).default,OpenStreetMapLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9971),r.e(6237)]).then(r.bind(r,66237))).default,OrientedImageryLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(4723),r.e(9238),r.e(178)]).then(r.bind(r,44958))).default,PointCloudLayer:async()=>(await Promise.all([r.e(163),r.e(8775),r.e(1767),r.e(7863)]).then(r.bind(r,10608))).default,RouteLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(1423),r.e(9206)]).then(r.bind(r,40153))).default,SceneLayer:async()=>(await Promise.all([r.e(163),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(6170),r.e(1767),r.e(2139),r.e(299)]).then(r.bind(r,57476))).default,StreamLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(5936)]).then(r.bind(r,88387))).default,SubtypeGroupLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(4723),r.e(7157),r.e(7021)]).then(r.bind(r,20697))).default,TileLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(4599),r.e(9735),r.e(9016),r.e(2725),r.e(8636)]).then(r.bind(r,98636))).default,UnknownLayer:async()=>(await r.e(4166).then(r.bind(r,44166))).default,UnsupportedLayer:async()=>(await r.e(9296).then(r.bind(r,39296))).default,VectorTileLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9016),r.e(4325),r.e(9805),r.e(5481)]).then(r.bind(r,94756))).default,VoxelLayer:async()=>(await Promise.all([r.e(163),r.e(8775),r.e(1767),r.e(7528)]).then(r.bind(r,28865))).default,WFSLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7899),r.e(957),r.e(1423),r.e(3778),r.e(7215),r.e(8089),r.e(7740)]).then(r.bind(r,12653))).default,WMSLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9790),r.e(8775),r.e(7915)]).then(r.bind(r,25906))).default,WMTSLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9971),r.e(2594)]).then(r.bind(r,72594))).default,WebTileLayer:async()=>(await Promise.all([r.e(163),r.e(4609),r.e(9971)]).then(r.bind(r,16199))).default}},33516:(e,a,r)=>{r.d(a,{M4:()=>o,Yv:()=>l,ht:()=>i,wk:()=>s});var t=r(17452),n=r(48522);function i(e){return{origin:"portal-item",url:(0,t.mN)(e.itemUrl),portal:e.portal||n.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function l(e){const a=(0,t.mN)(e.itemUrl);return{origin:"portal-item",messages:[],writtenProperties:[],url:a,portal:e.portal||n.Z.getDefault(),portalItem:e,verifyItemRelativeUrls:a?{rootPath:a.path,writtenUrls:[]}:null,blockedRelativeUrls:[]}}function s(e){return{origin:"web-map",url:(0,t.mN)(e.itemUrl),portal:e.portal||n.Z.getDefault(),portalItem:e,readResourcePaths:[]}}function o(e,a){const r=(0,t.mN)(e.itemUrl);return{origin:"web-map",messages:[],writtenProperties:[],url:r,portal:e.portal||n.Z.getDefault(),portalItem:e,initiator:a,verifyItemRelativeUrls:r?{rootPath:r.path,writtenUrls:[]}:null,blockedRelativeUrls:[],resources:{toAdd:[],toUpdate:[],toKeep:[],pendingOperations:[]}}}},18062:(e,a,r)=>{r.d(a,{load:()=>L});var t=r(20102),n=r(66677),i=r(52104),l=r(7335),s=r(70024),o=r(87344),c=r(48522),y=r(33516),u=r(3072),d=r(14661),p=r(40555),f=r(96187);async function L(e,a){const r=e.instance.portalItem;if(r?.id)return await r.load(a),function(e){const a=e.instance.portalItem;if(!a?.type||!e.supportedTypes.includes(a.type))throw new t.Z("portal:invalid-layer-item-type","Invalid layer item type '${type}', expected '${expectedType}'",{type:a?.type,expectedType:e.supportedTypes.join(", ")})}(e),async function(e,a){const r=e.instance,n=r.portalItem;if(!n)return;const{url:o,title:c}=n,L=(0,y.ht)(n);if("group"===r.type)return async function(e,a,r){const n=e.portalItem;if(!e.sourceIsPortalItem)return;const{title:o,type:c}=n;if("Group Layer"===c){if(!(0,d._$)(n,"Map"))throw new t.Z("portal:invalid-layer-item-typekeyword","'Group Layer' item without 'Map' type keyword is not supported");return async function(e){const a=e.portalItem,r=await a.fetchData("json");if(!r)return;const t=(0,y.wk)(a);e.read(r,t),await(0,s.k)(e,r,{context:t}),e.resourceReferences={portalItem:a,paths:t.readResourcePaths??[]}}(e)}return e.read({title:o},a),async function(e,a){let r;const{portalItem:n}=e;if(!n)return;const s=n.type,o=a.layerModuleTypeMap;switch(s){case"Feature Service":case"Feature Collection":r=o.FeatureLayer;break;case"Stream Service":r=o.StreamLayer;break;case"Scene Service":r=o.SceneLayer;break;default:throw new t.Z("portal:unsupported-item-type-as-group",`The item type '${s}' is not supported as a 'IGroupLayer'`)}const c=new l.L;let[y,d]=await Promise.all([r(),S(a,c)]),p=()=>y;if("Feature Service"===s){d=n.url?await(0,u.$O)(d,n.url,c):{};const a=(0,u.XX)(d),r=(0,u._Y)(d),t=[];if(a.length||r?.length){a.length&&t.push("SubtypeGroupLayer"),r?.length&&t.push("OrientedImageryLayer");const e=[];for(const a of t){const r=o[a];e.push(r())}const n=await Promise.all(e),i=new Map;t.forEach(((e,a)=>{i.set(e,n[a])})),p=e=>e.layerType?i.get(e.layerType)??y:y}const l=await async function(e){const{layersJSON:a}=await(0,i.V)(e);if(!a)return null;const r=[...a.layers,...a.tables];return e=>r.find((a=>a.id===e.id))}(n.url);return await m(e,p,d,l)}return"Scene Service"===s&&n.url&&(d=await(0,u.CD)(n,d,c)),(0,u.Q4)(d)>0?await m(e,p,d):await async function(e,a){const{portalItem:r}=e;if(!r?.url)return;const t=await(0,f.T)(r.url);t&&m(e,a,{layers:t.layers?.map(u.bS),tables:t.tables?.map(u.bS)})}(e,p)}(e,r)}(r,L,e);o&&r.read({url:o},L);const w=new l.L,h=await S(e,w,a);return h&&r.read(h,L),r.resourceReferences={portalItem:n,paths:L.readResourcePaths??[]},"subtype-group"!==r.type&&r.read({title:c},L),(0,p.y)(r,L)}(e,a)}async function m(e,a,r,t){let n=r.layers||[];const i=r.tables||[];if("Feature Collection"===e.portalItem?.type?(n.forEach(((e,a)=>{e.id=a,"Table"===e?.layerDefinition?.type&&i.push(e)})),n=n.filter((e=>"Table"!==e?.layerDefinition?.type))):(n.reverse(),i.reverse()),n.forEach((n=>{const i=t?.(n);if(i||!t){const t=w(e,a(n),r,n,i);e.add(t)}})),i.length){const a=await o.T.FeatureLayer();i.forEach((n=>{const i=t?.(n);if(i||!t){const t=w(e,a,r,n,i);e.tables.add(t)}}))}}function w(e,a,r,t,n){const i=e.portalItem,l={portalItem:i.clone(),layerId:t.id};null!=t.url&&(l.url=t.url);const s=new a(l);if("sourceJSON"in s&&(s.sourceJSON=n),"subtype-group"!==s.type&&(s.sublayerTitleMode="service-name"),"Feature Collection"===i.type){const e={origin:"portal-item",portal:i.portal||c.Z.getDefault()};s.read(t,e);const a=r.showLegend;null!=a&&s.read({showLegend:a},e)}return s}async function S(e,a,r){if(!1===e.supportsData)return;const t=e.instance,i=t.portalItem;if(!i)return;let l=null;try{l=await i.fetchData("json",r)}catch(e){}if(function(e){return"stream"!==e.type&&"layerId"in e}(t)){let e=null;const r=await async function(e,a,r){if(a?.layers&&a?.tables)return(0,u.Q4)(a);const t=(0,n.Qc)(e.url);if(!t)return 1;const i=await r.fetchServiceMetadata(t.url.path).catch((()=>null));return(a?.layers?.length??i?.layers?.length??0)+(a?.tables?.length??i?.tables?.length??0)}(i,l,a);if((l?.layers||l?.tables)&&r>0){if(null==t.layerId){const e=(0,u.XX)(l);t.layerId="subtype-group"===t.type?e?.[0]:(0,u.Ok)(l)}e=function(e,a){const{layerId:r}=a,t=e.layers?.find((e=>e.id===r))||e.tables?.find((e=>e.id===r));return t&&function(e,a){return!("feature"===a.type&&"layerType"in e&&"SubtypeGroupLayer"===e.layerType||"subtype-group"===a.type&&!("layerType"in e))}(t,a)?t:null}(l,t),e&&null!=l.showLegend&&(e.showLegend=l.showLegend)}return r>1&&"sublayerTitleMode"in t&&"service-name"!==t.sublayerTitleMode&&(t.sublayerTitleMode="item-title-and-service-name"),e}return l}},3072:(e,a,r)=>{r.d(a,{$O:()=>i,CD:()=>y,Ok:()=>l,Q4:()=>s,XX:()=>o,_Y:()=>c,bS:()=>n});var t=r(71592);function n(e){const a={id:e.id,name:e.name};return"Oriented Imagery Layer"===e.type&&(a.layerType="OrientedImageryLayer"),a}async function i(e,a,r){if(null==e?.layers||null==e?.tables){const t=await r.fetchServiceMetadata(a);(e=e||{}).layers=e.layers||t?.layers?.map(n),e.tables=e.tables||t?.tables?.map(n)}return e}function l(e){const a=e.layers;if(a?.length)return a[0].id;const r=e.tables;return r?.length?r[0].id:null}function s(e){return(e?.layers?.length??0)+(e?.tables?.length??0)}function o(e){const a=[];return e?.layers?.forEach((e=>{"SubtypeGroupLayer"===e.layerType&&a.push(e.id)})),a}function c(e){return e?.layers?.filter((({layerType:e})=>"OrientedImageryLayer"===e)).map((({id:e})=>e))}async function y(e,a,r){if(!e?.url)return a??{};if(a??={},!a.layers){const t=await r.fetchServiceMetadata(e.url);a.layers=t.layers?.map(n)}const{serverUrl:i,portalItem:l}=await(0,t.w)(e.url,{sceneLayerItem:e}).catch((()=>({serverUrl:null,portalItem:null})));if(null==i)return a.tables=[],a;if(!a.tables&&l){const e=await l.fetchData();if(e?.tables)a.tables=e.tables.map(n);else{const e=await r.fetchServiceMetadata(i);a.tables=e?.tables?.map(n)}}if(a.tables)for(const e of a.tables)e.url=`${i}/${e.id}`;return a}},28008:(e,a,r)=>{r.d(a,{fromItem:()=>u,v:()=>d});var t=r(20102),n=r(71592),i=r(7335),l=r(84230),s=r(87344),o=r(15235),c=r(3072),y=r(14661);async function u(e){!e.portalItem||e.portalItem instanceof o.default||(e={...e,portalItem:new o.default(e.portalItem)});const a=await async function(e){await e.load();const a=new i.L;return async function(e){const a=e.className,r=s.T[a];return{constructor:await r(),properties:e.properties}}(await d(e,a))}(e.portalItem);return new(0,a.constructor)({portalItem:e.portalItem,...a.properties})}async function d(e,a){switch(e.type){case"Map Service":return async function(e,a){return await async function(e,a){return(await a.fetchServiceMetadata(e.url)).tileInfo}(e,a)?{className:"TileLayer"}:{className:"MapImageLayer"}}(e,a);case"Feature Service":return async function(e,a){const r=await p(e,a);if("object"==typeof r){const e={};return null!=r.id&&(e.layerId=r.id),{className:r.className||"FeatureLayer",properties:e}}return{className:"GroupLayer"}}(e,a);case"Feature Collection":return async function(e){await e.load();const a=(0,y._$)(e,"Map Notes"),r=(0,y._$)(e,"Markup");if(a||r)return{className:"MapNotesLayer"};if((0,y._$)(e,"Route Layer"))return{className:"RouteLayer"};const t=await e.fetchData();return 1===(0,c.Q4)(t)?{className:"FeatureLayer"}:{className:"GroupLayer"}}(e);case"Scene Service":return async function(e,a){const r=await p(e,a,(async()=>{try{if(!e.url)return[];const{serverUrl:r}=await(0,n.w)(e.url,{sceneLayerItem:e}),t=await a.fetchServiceMetadata(r);return t?.tables??[]}catch{return[]}}));if("object"==typeof r){const t={};let n;if(null!=r.id?(t.layerId=r.id,n=`${e.url}/layers/${r.id}`):n=e.url,e.typeKeywords?.length)for(const a of Object.keys(l.fb))if(e.typeKeywords.includes(a))return{className:l.fb[a]};const i=await a.fetchServiceMetadata(n);return{className:l.fb[i?.layerType]||"SceneLayer",properties:t}}if(!1===r){const r=await a.fetchServiceMetadata(e.url);if("Voxel"===r?.layerType)return{className:"VoxelLayer"}}return{className:"GroupLayer"}}(e,a);case"Image Service":return async function(e,a){await e.load();const r=e.typeKeywords?.map((e=>e.toLowerCase()))??[];if(r.includes("elevation 3d layer"))return{className:"ElevationLayer"};if(r.includes("tiled imagery"))return{className:"ImageryTileLayer"};const t=await e.fetchData(),n=t?.layerType;if("ArcGISTiledImageServiceLayer"===n)return{className:"ImageryTileLayer"};if("ArcGISImageServiceLayer"===n)return{className:"ImageryLayer"};const i=await a.fetchServiceMetadata(e.url),l=i.cacheType?.toLowerCase(),s=i.capabilities?.toLowerCase().includes("tilesonly");return"map"===l||s?{className:"ImageryTileLayer"}:{className:"ImageryLayer"}}(e,a);case"Stream Service":case"Feed":return{className:"StreamLayer"};case"Vector Tile Service":return{className:"VectorTileLayer"};case"GeoJson":return{className:"GeoJSONLayer"};case"CSV":return{className:"CSVLayer"};case"KML":return{className:"KMLLayer"};case"WFS":return{className:"WFSLayer"};case"WMTS":return{className:"WMTSLayer"};case"WMS":return{className:"WMSLayer"};case"Group Layer":return{className:"GroupLayer"};default:throw new t.Z("portal:unknown-item-type","Unknown item type '${type}'",{type:e.type})}}async function p(e,a,r){const t=e.url;if(!t||/\/\d+$/.test(t))return{};await e.load();let n=await e.fetchData();if("Feature Service"===e.type){const e=await(0,c.$O)(n,t,a),r=f(e);if("object"==typeof r){const a=(0,c.XX)(e),t=(0,c._Y)(e);r.className=null!=r.id&&a.includes(r.id)?"SubtypeGroupLayer":null!=r.id&&t?.includes(r.id)?"OrientedImageryLayer":"FeatureLayer"}return r}if("Scene Service"===e.type&&(n=await(0,c.CD)(e,n,a)),(0,c.Q4)(n)>0)return f(n);const i=await a.fetchServiceMetadata(t);return r&&(i.tables=await r()),f(i)}function f(e){return 1===(0,c.Q4)(e)&&{id:(0,c.Ok)(e)}}},40555:(e,a,r)=>{r.d(a,{y:()=>l});var t=r(66643),n=r(95330),i=r(20941);async function l(e,a,r){const l=e&&e.getAtOrigin&&e.getAtOrigin("renderer",a.origin);if(l&&"unique-value"===l.type&&l.styleOrigin){const s=await(0,t.q6)(l.populateFromStyle());if((0,n.k_)(r),!1===s.ok){const r=s.error;a?.messages&&a.messages.push(new i.Z("renderer:style-reference",`Failed to create unique value renderer from style reference: ${r.message}`,{error:r,context:a})),e.clear("renderer",a?.origin)}}}},96187:(e,a,r)=>{r.d(a,{T:()=>n});var t=r(3172);async function n(e,a){const{data:r}=await(0,t.Z)(e,{responseType:"json",query:{f:"json",...a?.customParameters,token:a?.apiKey}});return r}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7157],{22862:(e,t,r)=>{r.d(t,{Hg:()=>h,V7:()=>c,uD:()=>y});var s=r(92036),i=r(46791),o=r(1153);const n=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function a(e){return e instanceof s.Z}function l(e){return e instanceof i.Z?Object.keys(e.items):a(e)?(0,o.vw)(e).keys():e?Object.keys(e):[]}function p(e,t){return e instanceof i.Z?e.items[t]:e[t]}function u(e){return e?e.declaredClass:null}function d(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const s=l(e),i=l(t);if(0===s.length&&0===i.length)return;if(!s.length||!i.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const o=i.filter((e=>!s.includes(e))),y=s.filter((e=>!i.includes(e))),c=s.filter((r=>i.includes(r)&&p(e,r)!==p(t,r))).concat(o,y).sort(),h=u(e);if(h&&n.has(h)&&c.length)return{type:"complete",oldValue:e,newValue:t};let f;const b=a(e)&&a(t);for(const s of c){const i=p(e,s),o=p(t,s);let n;if((b||"function"!=typeof i&&"function"!=typeof o)&&i!==o&&(null!=i||null!=o)){if(r&&r[s]&&"function"==typeof r[s])n=r[s]?.(i,o);else if(i instanceof Date&&o instanceof Date){if(i.getTime()===o.getTime())continue;n={type:"complete",oldValue:i,newValue:o}}else n="object"==typeof i&&"object"==typeof o&&u(i)===u(o)?d(i,o):{type:"complete",oldValue:i,newValue:o};null!=n&&(null!=f?f.diff[s]=n:f={type:"partial",diff:{[s]:n}})}}return f}function y(e,t){if(null==e)return!1;const r=t.split(".");let s=e;for(const e of r){if("complete"===s.type)return!0;if("partial"!==s.type)return!1;{const t=s.diff[e];if(!t)return!1;s=t}}return!0}function c(e,t){for(const r of t)if(y(e,r))return!0;return!1}function h(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&u(e)!==u(t)?{type:"complete",oldValue:e,newValue:t}:d(e,t)}},20697:(e,t,r)=>{r.r(t),r.d(t,{default:()=>we});var s=r(43697),i=r(2368),o=r(46791),n=r(20102),a=r(68668),l=r(16453),p=r(95330),u=r(17445),d=r(42033),y=r(17452),c=r(5600),h=(r(75215),r(67676),r(80442),r(71715)),f=r(52011),b=r(31263),g=r(87085),m=r(54295),v=r(17287),w=r(71612),C=r(17017),S=r(66361),_=r(25113),F=r(38009),A=r(16859),I=r(34760),T=r(72965),E=r(28294),O=r(66677),j=r(21506),x=r(45574),R=r(53518),P=r(69165),L=r(51773),D=r(16050),Q=(r(12501),r(28756),r(92271),r(72529),r(5499)),Z=r(84382),M=r(81571),V=(r(91423),r(92604)),G=r(10699),q=r(22974),k=r(83379),U=r(78286),H=r(30556),z=r(63213),N=r(90100),B=r(70082),$=r(54306),K=r(30707),W=r(14165),J=r(32163),Y=r(28412);const X=["charts","editingEnabled","formTemplate","labelsVisible","labelingInfo","legendEnabled","minScale","maxScale","opacity","popupEnabled","popupTemplate","renderer","subtypeCode","templates","title","visible"],ee={key:"type",base:Q.Z,errorContext:"renderer",typeMap:{simple:Z.Z,"unique-value":M.Z,"class-breaks":D.Z}},te=(0,R.v)(),re=(0,z.d)({types:ee});let se=0;function ie(e){const t=e.json.write;return"object"==typeof t?t.ignoreOrigin=!0:e.json.write={ignoreOrigin:!0},e}function oe(e){switch(e){case"point":case"multipoint":return Y.xA.clone();case"polyline":return Y.CJ.clone();case"polygon":case"multipatch":return Y.z3.clone();default:return null}}function ne(e,t){return null==e?null:t.subtypes?.find((t=>t.code===e))}function ae(e,t){let r=null;switch(t.geometryType){case"esriGeometryPoint":case"esriGeometryMultipoint":r="point";break;case"esriGeometryPolyline":r="line";break;case"esriGeometryPolygon":case"esriGeometryMultiPatch":r="polygon";break;default:t.type,r=null}const s={},i=ne(e,t);if(null!=i){const{defaultValues:e}=i;for(const t in e)s[t]=e[t]}return s[t.subtypeField]=e,new B.Z({name:"New Feature",drawingTool:r,prototype:{attributes:s}})}const le="esri.layers.support.SubtypeSublayer";let pe=class extends((0,l.R)((0,i.J)((0,G.IG)(k.Z)))){constructor(e){super(e),this.charts=null,this.editingEnabled=!0,this.fieldOverrides=null,this.fieldsIndex=null,this.formTemplate=null,this.id=`${Date.now().toString(16)}-subtype-sublayer-${se++}`,this.type="subtype-sublayer",this.labelsVisible=!0,this.labelingInfo=null,this.layerType="ArcGISFeatureLayer",this.legendEnabled=!0,this.listMode="show",this.minScale=0,this.maxScale=0,this.opacity=1,this.parent=null,this.popupEnabled=!0,this.popupTemplate=null,this.subtypeCode=null,this.templates=null,this.title=null,this.visible=!0}get capabilities(){return this.parent?.capabilities}get effectiveCapabilities(){return this.parent?.effectiveCapabilities}get effectiveEditingEnabled(){const{parent:e}=this;return e?e.effectiveEditingEnabled&&this.editingEnabled:this.editingEnabled}get elevationInfo(){return this.parent?.elevationInfo}writeFieldOverrides(e,t,r){const{fields:s,parent:i}=this;let o;if(s){o=[];let e=0;s.forEach((({name:t,alias:r,editable:s,visible:n})=>{if(!n)return;const a=i?.fields?.find((e=>e.name===t));if(!a)return;const l={name:t};let p=!1;r!==a.alias&&(l.alias=r,p=!0),s!==a.editable&&(l.editable=s,p=!0),o.push(l),p&&e++})),0===e&&o.length===s.length&&(o=null)}else o=(0,q.d9)(e);o?.length&&(0,U.RB)(r,o,t)}get fields(){const{parent:e,fieldOverrides:t,subtypeCode:r}=this,s=e?.fields;if(!e||!s?.length)return null;const{subtypes:i,subtypeField:o}=e,n=i?.find((e=>e.code===r)),a=n?.defaultValues,l=n?.domains,p=[];for(const e of s){const s=e.clone(),{name:i}=s,n=t?.find((e=>e.name===i));if(s.visible=!t||!!n,n){const{alias:e,editable:t}=n;e&&(s.alias=e),!1===t&&(s.editable=!1)}const u=a?.[i]??null;s.defaultValue=i===o?r:u;const d=l?.[i]??null;s.domain=i===o?null:d?"inherited"===d.type?s.domain:d.clone():null,p.push(s)}return p}get floorInfo(){return this.parent?.floorInfo}get geometryType(){return this.parent?.geometryType}get effectiveScaleRange(){const{minScale:e,maxScale:t}=this;return{minScale:e,maxScale:t}}get objectIdField(){return this.parent||V.Z.getLogger(le).error(de("objectIdField")),this.parent?.objectIdField}get defaultPopupTemplate(){return this.createPopupTemplate()}set renderer(e){(0,P.YN)(e,this.fieldsIndex),this._override("renderer",e)}get renderer(){if(this._isOverridden("renderer"))return this._get("renderer");const{parent:e}=this;return e&&!e.isTable&&"mesh"!==e.geometryType?function(e){return new Z.Z({symbol:oe(e)})}(e.geometryType):null}readRendererFromService(e,t,r){if("Table"===t.type)return null;const s=t.drawingInfo?.renderer,i=re(s,t,r);let o;const{subtypeCode:n}=this;if(null!=n&&function(e,t){return!(!t||"unique-value"!==e?.type||"string"!=typeof e.field||e.field.toLowerCase()!==t.toLowerCase()||e.field2||e.field3||e.valueExpression)}(i,t.subtypeField)){const e=i.uniqueValueInfos?.find((({value:e})=>(e="number"==typeof e?String(e):e)===String(n)));e&&(o=new Z.Z({symbol:e.symbol}))}else"simple"!==i?.type||i.visualVariables?.length||(o=i);return o}readRenderer(e,t,r){const s=t?.layerDefinition?.drawingInfo?.renderer;if(!s)return;const i=s.visualVariables?.some((e=>"rotationInfo"!==e.type));return i?void 0:re(s,t,r)||void 0}get spatialReference(){return this.parent?.spatialReference}readTemplatesFromService(e,t){return[ae(this.subtypeCode,t)]}readTitleFromService(e,t){const r=ne(this.subtypeCode,t);return null!=r?r.name:null}get url(){return this.parent?.url}get userHasUpdateItemPrivileges(){return!!this.parent?.userHasUpdateItemPrivileges}async addAttachment(e,t){const{parent:r}=this;if(!r)throw de("addAttachment");if(e.getAttribute(r.subtypeField)!==this.subtypeCode)throw new n.Z("subtype-sublayer:addAttachment","The feature provided does not belong to this SubtypeSublayer");return r.addAttachment(e,t)}async updateAttachment(e,t,r){const{parent:s}=this;if(!s)throw de("updateAttachment");if(e.getAttribute(s.subtypeField)!==this.subtypeCode)throw new n.Z("subtype-sublayer:updateAttachment","The feature provided does not belong to this SubtypeSublayer");return s.updateAttachment(e,t,r)}async deleteAttachments(e,t){const{parent:r}=this;if(!r)throw de("deleteAttachments");if(e.getAttribute(r.subtypeField)!==this.subtypeCode)throw new n.Z("subtype-sublayer:deleteAttachments","The feature provided does not belong to this SubtypeSublayer");return r.deleteAttachments(e,t)}async applyEdits(e,t){if(!this.parent)throw de("applyEdits");return this.parent.applyEdits(e,t)}createPopupTemplate(e){let t=this;const{parent:r,fields:s,title:i}=this;if(r){const{displayField:e,editFieldsInfo:o,objectIdField:n}=r;t={displayField:e,editFieldsInfo:o,fields:s,objectIdField:n,title:i}}return(0,J.eZ)(t,e)}createQuery(){if(!this.parent)throw de("createQuery");const e=(0,x.rP)(this.parent),t=`${this.parent.subtypeField}=${this.subtypeCode}`;return e.where=(0,d._)(t,this.parent.definitionExpression),e}getField(e){return this.fieldsIndex.get(e)}getFieldDomain(e){return this._getLayerDomain(e)}hasUserOverrides(){return X.some((e=>this.originIdOf(e)===b.s3.USER))}async queryAttachments(e,t){const r=await this.load();if(!r.parent)throw de("queryAttachments");const s=e.clone();return s.where=ue(s.where,r.parent.subtypeField,r.subtypeCode),r.parent.queryAttachments(e,t)}async queryFeatures(e,t){const r=await this.load();if(!r.parent)throw de("queryFeatures");const s=W.Z.from(e)??r.createQuery();return null!=e&&(s.where=ue(s.where,r.parent.subtypeField,r.subtypeCode)),r.parent.queryFeatures(s,t)}_getLayerDomain(e){const t=this.fieldsIndex.get(e);return t?t.domain:null}};(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"capabilities",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"effectiveCapabilities",null),(0,s._)([(0,c.Cb)({json:{write:{ignoreOrigin:!0}}})],pe.prototype,"charts",void 0),(0,s._)([(0,c.Cb)({type:Boolean,nonNullable:!0,json:{name:"enableEditing",write:{ignoreOrigin:!0}}})],pe.prototype,"editingEnabled",void 0),(0,s._)([(0,c.Cb)({type:Boolean,readOnly:!0})],pe.prototype,"effectiveEditingEnabled",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"elevationInfo",null),(0,s._)([(0,c.Cb)({json:{name:"layerDefinition.fieldOverrides",origins:{service:{read:!1}},write:{ignoreOrigin:!0,allowNull:!0}}})],pe.prototype,"fieldOverrides",void 0),(0,s._)([(0,H.c)("fieldOverrides")],pe.prototype,"writeFieldOverrides",null),(0,s._)([(0,c.Cb)({...te.fields,readOnly:!0,json:{read:!1}})],pe.prototype,"fields",null),(0,s._)([(0,c.Cb)(te.fieldsIndex)],pe.prototype,"fieldsIndex",void 0),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"floorInfo",null),(0,s._)([(0,c.Cb)({type:N.Z,json:{name:"formInfo",write:{ignoreOrigin:!0}}})],pe.prototype,"formTemplate",void 0),(0,s._)([(0,c.Cb)({type:String,clonable:!1,readOnly:!0,json:{origins:{service:{read:!1}},write:{ignoreOrigin:!0}}})],pe.prototype,"id",void 0),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"geometryType",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"type",void 0),(0,s._)([(0,c.Cb)(ie((0,q.d9)(j.iR)))],pe.prototype,"labelsVisible",void 0),(0,s._)([(0,c.Cb)({type:[$.Z],json:{name:"layerDefinition.drawingInfo.labelingInfo",origins:{service:{read:!1}},read:{reader:K.r},write:{ignoreOrigin:!0}}})],pe.prototype,"labelingInfo",void 0),(0,s._)([(0,c.Cb)({type:["ArcGISFeatureLayer"],readOnly:!0,json:{read:!1,write:{ignoreOrigin:!0}}})],pe.prototype,"layerType",void 0),(0,s._)([(0,c.Cb)(ie((0,q.d9)(j.rn)))],pe.prototype,"legendEnabled",void 0),(0,s._)([(0,c.Cb)({type:["show","hide"]})],pe.prototype,"listMode",void 0),(0,s._)([(0,c.Cb)((()=>{const e=(0,q.d9)(j.rO);return e.json.origins.service.read=!1,ie(e)})())],pe.prototype,"minScale",void 0),(0,s._)([(0,c.Cb)((()=>{const e=(0,q.d9)(j.u1);return e.json.origins.service.read=!1,ie(e)})())],pe.prototype,"maxScale",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],pe.prototype,"effectiveScaleRange",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"objectIdField",null),(0,s._)([(0,c.Cb)({type:Number,range:{min:0,max:1},nonNullable:!0,json:{write:{ignoreOrigin:!0}}})],pe.prototype,"opacity",void 0),(0,s._)([(0,c.Cb)({clonable:!1})],pe.prototype,"parent",void 0),(0,s._)([(0,c.Cb)(ie((0,q.d9)(j.C_)))],pe.prototype,"popupEnabled",void 0),(0,s._)([(0,c.Cb)({type:L.Z,json:{name:"popupInfo",write:{ignoreOrigin:!0}}})],pe.prototype,"popupTemplate",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],pe.prototype,"defaultPopupTemplate",null),(0,s._)([(0,c.Cb)({types:ee,json:{write:{target:"layerDefinition.drawingInfo.renderer",ignoreOrigin:!0}}})],pe.prototype,"renderer",null),(0,s._)([(0,h.r)("service","renderer",["drawingInfo.renderer","subtypeField","type"])],pe.prototype,"readRendererFromService",null),(0,s._)([(0,h.r)("renderer",["layerDefinition.drawingInfo.renderer"])],pe.prototype,"readRenderer",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"spatialReference",null),(0,s._)([(0,c.Cb)({type:Number,json:{origins:{service:{read:!1}},write:{ignoreOrigin:!0}}})],pe.prototype,"subtypeCode",void 0),(0,s._)([(0,c.Cb)({type:[B.Z],json:{name:"layerDefinition.templates",write:{ignoreOrigin:!0}}})],pe.prototype,"templates",void 0),(0,s._)([(0,h.r)("service","templates",["geometryType","subtypeField","subtypes","type"])],pe.prototype,"readTemplatesFromService",null),(0,s._)([(0,c.Cb)({type:String,json:{write:{ignoreOrigin:!0}}})],pe.prototype,"title",void 0),(0,s._)([(0,h.r)("service","title",["subtypes"])],pe.prototype,"readTitleFromService",null),(0,s._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],pe.prototype,"url",null),(0,s._)([(0,c.Cb)({readOnly:!0})],pe.prototype,"userHasUpdateItemPrivileges",null),(0,s._)([(0,c.Cb)({type:Boolean,nonNullable:!0,json:{name:"visibility",write:{ignoreOrigin:!0}}})],pe.prototype,"visible",void 0),pe=(0,s._)([(0,f.j)(le)],pe);const ue=(e,t,r)=>{const s=new RegExp(`${t}\\s*=\\s*\\d+`),i=`${t}=${r}`,o=e??"";return s.test(o)?o.replace(s,i):(0,d._)(i,o)},de=e=>new n.Z(`This sublayer must have a parent SubtypeGroupLayer in order to use ${e}`),ye=pe;var ce=r(76259),he=r(60199),fe=r(12259);const be="SubtypeGroupLayer";function ge(e,t){return new n.Z("layer:unsupported",`Layer (${e.title}, ${e.id}) of type '${e.declaredClass}' ${t}`,{layer:e})}const me=(0,R.v)();let ve=class extends((0,_.B)((0,S.o1)((0,w.h)((0,E.n)((0,T.M)((0,I.Q)((0,v.Y)((0,F.q)((0,A.I)((0,l.R)((0,C.N)((0,m.V)((0,i.J)(g.Z)))))))))))))){constructor(...e){super(...e),this._sublayersCollectionChanged=!1,this._sublayerLookup=new Map,this.fields=null,this.fieldsIndex=null,this.outFields=null,this.sublayers=new(o.Z.ofType(ye)),this.timeInfo=null,this.title="Layer",this.type="subtype-group",this._debouncedSaveOperations=(0,p.Ds)((async(e,t,s)=>{const{save:i,saveAs:o}=await r.e(2664).then(r.bind(r,32664));switch(e){case fe.x.SAVE:return i(this,t);case fe.x.SAVE_AS:return o(this,s,t)}})),this.addHandles((0,u.YP)((()=>this.sublayers),((e,t)=>this._handleSublayersChange(e,t)),u.Z_))}destroy(){this.source?.destroy()}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Feature Service"]},e).catch(p.r9).then((async()=>{if(!this.url)throw new n.Z("subtype-grouplayer:missing-url-or-source","SubtypeGroupLayer must be created with either a url or a portal item");if(null==this.layerId)throw new n.Z("subtype-grouplayer:missing-layerid","layerId is required for a SubtypeGroupLayer created with url");return this._initLayerProperties(await this.createGraphicsSource(t))})).then((()=>(0,x.nU)(this,"load",e)));return this.addResolvingPromise(r),Promise.resolve(this)}get createQueryVersion(){return this.commitProperty("definitionExpression"),this.commitProperty("timeExtent"),this.commitProperty("timeOffset"),this.commitProperty("geometryType"),this.commitProperty("gdbVersion"),this.commitProperty("historicMoment"),this.commitProperty("returnZ"),this.commitProperty("capabilities"),this.commitProperty("returnM"),(this._get("createQueryVersion")??0)+1}get editingEnabled(){return this.loaded&&null!=this.capabilities&&this.capabilities.operations.supportsEditing&&this.userHasEditingPrivileges}get effectiveEditingEnabled(){return(0,x.sX)(this)}get parsedUrl(){const e=(0,y.mN)(this.url);return null!=e&&null!=this.layerId&&(e.path=(0,y.v_)(e.path,this.layerId.toString())),e}set source(e){this._get("source")!==e&&this._set("source",e)}readTitleFromService(e,{name:t}){return this.url?(0,O.a7)(this.url,t):t}async addAttachment(e,t){return(0,x.JD)(this,e,t,be)}async updateAttachment(e,t,r){return(0,x.Y5)(this,e,t,r,be)}async applyEdits(e,t){return(0,x.Jj)(this,e,t)}on(e,t){return super.on(e,t)}async createGraphicsSource(e){const{default:t}=await(0,p.Hl)(Promise.all([r.e(4599),r.e(9735),r.e(6882)]).then(r.bind(r,49379)),e);return new t({layer:this}).load({signal:e})}createQuery(){const e=(0,x.rP)(this),t=this.sublayers.map((e=>e.subtypeCode));return e.where=(0,d._)(`${this.subtypeField} IN (${t.join(",")})`,this.definitionExpression),e}async deleteAttachments(e,t){return(0,x.FV)(this,e,t,be)}async fetchRecomputedExtents(e){return(0,x.Ci)(this,e,be)}findSublayerForFeature(e){const t=this.fieldsIndex.get(this.subtypeField),r=e.attributes[t.name];return this.findSublayerForSubtypeCode(r)}findSublayerForSubtypeCode(e){return this._sublayerLookup.get(e)}getFieldDomain(e,t){return this._getLayerDomain(e)}getField(e){return this.fieldsIndex.get(e)}loadAll(){return(0,a.G)(this,(e=>{e(this.sublayers)}))}async queryAttachments(e,t){return(0,x.SU)(this,e,t,be)}async queryFeatures(e,t){const r=await this.load(),s=W.Z.from(e)??r.createQuery(),i=s.outFields??[];i.includes(this.subtypeField)||(i.push(this.subtypeField),s.outFields=i);const o=await r.source.queryFeatures(s,t);if(o?.features)for(const e of o.features)e.layer=e.sourceLayer=this.findSublayerForFeature(e);return o}async queryObjectIds(e,t){return(0,x.tD)(this,e,t,be)}async queryFeatureCount(e,t){return(0,x.VG)(this,e,t,be)}async queryExtent(e,t){return(0,x.KE)(this,e,t,be)}async queryRelatedFeatures(e,t){return(0,x.kp)(this,e,t,be)}async queryRelatedFeaturesCount(e,t){return(0,x.C9)(this,e,t,be)}async save(e){return this._debouncedSaveOperations(fe.x.SAVE,e)}async saveAs(e,t){return this._debouncedSaveOperations(fe.x.SAVE_AS,t,e)}write(e,t){const{origin:r,layerContainerType:s,messages:i}=t;if(this.isTable){if("web-scene"===r||"web-map"===r&&"tables"!==s)return i?.push(ge(this,"using a table source cannot be written to web scenes and web maps")),null}else if(this.loaded&&"web-map"===r&&"tables"===s)return i?.push(ge(this,"using a non-table source cannot be written to tables in web maps")),null;return this.sublayers?.length?super.write(e,t):(i?.push(new n.Z("web-document-write:invalid-property",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' has invalid value for 'sublayers' property. 'sublayers' collection should contain at least one sublayer`,{layer:this})),null)}serviceSupportsSpatialReference(e){return!!this.loaded&&(0,he.D)(this,e)}_getLayerDomain(e){const t=this.fieldsIndex.get(e);return t?t.domain:null}async _initLayerProperties(e){this._set("source",e);const{sourceJSON:t}=e;if(t&&(this.sourceJSON=t,this.read(t,{origin:"service",url:this.parsedUrl})),this.isTable)throw new n.Z("subtype-grouplayer:unsupported-source","SubtypeGroupLayer cannot be created using a layer with table source");if(!this.subtypes?.length)throw new n.Z("subtype-grouplayer:missing-subtypes","SubtypeGroupLayer must be created using a layer with subtypes");this._verifyFields(),(0,P.UF)(this.timeInfo,this.fieldsIndex)}async hasDataChanged(){return(0,x.gG)(this)}_verifyFields(){const e=this.parsedUrl?.path??"undefined";this.objectIdField||console.log("SubtypeGroupLayer: 'objectIdField' property is not defined (url: "+e+")"),this.isTable||-1!==e.search(/\/FeatureServer\//i)||this.fields?.some((e=>"geometry"===e.type))||console.log("SubtypeGroupLayer: unable to find field of type 'geometry' in the layer 'fields' list. If you are using a map service layer, features will not have geometry (url: "+e+")")}_handleSublayersChange(e,t){t&&(t.forEach((e=>{e.parent=null})),this.removeHandles("sublayers-owner"),this._sublayerLookup.clear()),e&&(e.forEach((e=>{e.parent=this,this._sublayerLookup.set(e.subtypeCode,e)})),this._sublayersCollectionChanged=!1,this.addHandles([e.on("after-add",(({item:e})=>{e.parent=this,this._sublayerLookup.set(e.subtypeCode,e)})),e.on("after-remove",(({item:e})=>{e.parent=null,this._sublayerLookup.delete(e.subtypeCode)})),e.on("after-changes",(()=>{this._sublayersCollectionChanged=!0}))],"sublayers-owner"))}};(0,s._)([(0,c.Cb)({readOnly:!0})],ve.prototype,"createQueryVersion",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ve.prototype,"editingEnabled",null),(0,s._)([(0,c.Cb)({readOnly:!0})],ve.prototype,"effectiveEditingEnabled",null),(0,s._)([(0,c.Cb)({...me.fields,readOnly:!0,json:{origins:{service:{read:!0}},read:!1}})],ve.prototype,"fields",void 0),(0,s._)([(0,c.Cb)(me.fieldsIndex)],ve.prototype,"fieldsIndex",void 0),(0,s._)([(0,c.Cb)(j.id)],ve.prototype,"id",void 0),(0,s._)([(0,c.Cb)({type:["show","hide","hide-children"],json:{origins:{"portal-item":{read:!1,write:!1}}}})],ve.prototype,"listMode",void 0),(0,s._)([(0,c.Cb)({value:"SubtypeGroupLayer",type:["SubtypeGroupLayer"],json:{origins:{"portal-item":{name:"layerType",write:{enabled:!0,ignoreOrigin:!0}}}}})],ve.prototype,"operationalLayerType",void 0),(0,s._)([(0,c.Cb)(me.outFields)],ve.prototype,"outFields",void 0),(0,s._)([(0,c.Cb)({readOnly:!0})],ve.prototype,"parsedUrl",null),(0,s._)([(0,c.Cb)({clonable:!1})],ve.prototype,"source",null),(0,s._)([(0,c.Cb)({type:o.Z.ofType(ye),json:{origins:{service:{read:{source:"subtypes",reader:(e,t,r)=>{const s=e.map((({code:e})=>{const s=new ye({subtypeCode:e});return s.read(t,r),s}));return new(o.Z.ofType(ye))(s)}}}},name:"layers",write:{overridePolicy(e,t,r){const s=this.originOf("sublayers"),i=b.s3.PORTAL_ITEM;let o=!0;if((0,b.M9)(s)===i&&(0,b.M9)(r.origin)>i){const t=e.some((e=>e.hasUserOverrides()));o=this._sublayersCollectionChanged||t}return{enabled:o,ignoreOrigin:!0}}}}})],ve.prototype,"sublayers",void 0),(0,s._)([(0,c.Cb)({type:ce.Z})],ve.prototype,"timeInfo",void 0),(0,s._)([(0,c.Cb)({json:{origins:{"portal-item":{write:{enabled:!0,ignoreOrigin:!0,writerEnsuresNonNull:!0}}}}})],ve.prototype,"title",void 0),(0,s._)([(0,h.r)("service","title",["name"])],ve.prototype,"readTitleFromService",null),(0,s._)([(0,c.Cb)({json:{read:!1}})],ve.prototype,"type",void 0),ve=(0,s._)([(0,f.j)("esri.layers.SubtypeGroupLayer")],ve);const we=ve},54295:(e,t,r)=>{r.d(t,{V:()=>n});var s=r(43697),i=r(5600),o=(r(75215),r(67676),r(80442),r(52011));const n=e=>{let t=class extends e{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,s._)([(0,i.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,s._)([(0,o.j)("esri.layers.mixins.APIKeyMixin")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>l});var s=r(43697),i=r(92604),o=r(5600),n=(r(75215),r(67676),r(80442),r(52011)),a=r(66677);const l=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.Qc)(this.url);if(null!=e&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Nm)(e,i.Z.getLogger(this)))}};return(0,s._)([(0,o.Cb)()],t.prototype,"title",null),(0,s._)([(0,o.Cb)({type:String})],t.prototype,"url",null),t=(0,s._)([(0,n.j)("esri.layers.mixins.ArcGISService")],t),t}},17017:(e,t,r)=>{r.d(t,{N:()=>n});var s=r(43697),i=r(5600),o=(r(75215),r(67676),r(80442),r(52011));const n=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,s._)([(0,i.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,s._)([(0,o.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},34760:(e,t,r)=>{r.d(t,{Q:()=>v});var s=r(43697),i=r(92604),o=r(95330),n=r(5600),a=r(90578),l=(r(67676),r(80442),r(52011)),p=r(82960),u=r(46791),d=(r(66643),r(20102),r(26258),r(87538));const y=new u.Z,c=new WeakMap;function h(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&y.push(new WeakRef(e))}function f(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:f(t,e%t):0}let b=0,g=0;function m(){const e=Date.now();let t=!1;for(const r of y){const s=r.deref();s?s.refreshInterval&&e-(c.get(s)??0)+5>=6e4*s.refreshInterval&&(c.set(s,e),s.refresh(e)):t=!0}if(t)for(let e=y.length-1;e>=0;e--)y.at(e).deref()||y.removeAt(e)}(0,d.EH)((()=>{const e=Date.now();let t=0;for(const r of y){const s=r.deref();s&&(t=f(Math.round(6e4*s.refreshInterval),t),s.refreshInterval?c.get(s)||c.set(s,e):c.delete(s))}if(t!==g){if(g=t,clearInterval(b),0===g)return void(b=0);b=setInterval(m,g)}}));const v=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,o.Ds)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||h(this)}),(()=>{}))}destroy(){!function(e){const t=y.find((t=>t.deref()===e));t&&y.remove(t)}(this)}castRefreshInterval(e){return e>=.1?e:e<=0?0:.1}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,o.R8)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{i.Z.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){const e=this;return{set refreshInterval(t){e._set("refreshInterval",t)}}}};return(0,s._)([(0,n.Cb)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:p.C}}}}})],t.prototype,"refreshInterval",void 0),(0,s._)([(0,a.p)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,s._)([(0,n.Cb)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,s._)([(0,n.Cb)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,s._)([(0,l.j)("esri.layers.mixins.RefreshableLayer")],t),t}},70082:(e,t,r)=>{r.d(t,{Z:()=>d});var s=r(43697),i=r(2368),o=r(35454),n=r(96674),a=r(5600),l=(r(75215),r(67676),r(80442),r(52011));const p=new o.X({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let u=class extends((0,i.J)(n.wq)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,s._)([(0,a.Cb)({json:{write:!0}})],u.prototype,"name",void 0),(0,s._)([(0,a.Cb)({json:{write:!0}})],u.prototype,"description",void 0),(0,s._)([(0,a.Cb)({json:{read:p.read,write:p.write}})],u.prototype,"drawingTool",void 0),(0,s._)([(0,a.Cb)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,s._)([(0,a.Cb)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,s._)([(0,l.j)("esri.layers.support.FeatureTemplate")],u);const d=u},56765:(e,t,r)=>{r.d(t,{Z:()=>u});var s,i=r(43697),o=r(46791),n=r(96674),a=r(5600),l=(r(75215),r(67676),r(80442),r(52011));let p=s=class extends n.wq{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new o.Z}clone(){return new s({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,i._)([(0,a.Cb)({type:String,json:{write:!0}})],p.prototype,"floorField",void 0),(0,i._)([(0,a.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllMode",void 0),(0,i._)([(0,a.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllLevelIds",void 0),p=s=(0,i._)([(0,l.j)("esri.layers.support.LayerFloorInfo")],p);const u=p},54275:(e,t,r)=>{r.d(t,{h:()=>d});var s=r(80442),i=r(66677);function o(e,t,r){return!!a(e,t,r)}function n(e,t,r){return a(e,t,r)}function a(e,t,r){return e&&e.hasOwnProperty(t)?e[t]:r}const l={name:"supportsName",size:"supportsSize",contentType:"supportsContentType",keywords:"supportsKeywords",exifInfo:"supportsExifInfo"};function p(e){const t=e?.supportedSpatialAggregationStatistics?.map((e=>e.toLowerCase()));return{envelope:!!t?.includes("envelopeaggregate"),centroid:!!t?.includes("centroidaggregate"),convexHull:!!t?.includes("convexhullaggregate")}}function u(e,t){const r=e?.supportedOperationsWithCacheHint?.map((e=>e.toLowerCase()));return!!r?.includes(t.toLowerCase())}function d(e,t){return{analytics:y(e),attachment:c(e),data:h(e),metadata:f(e),operations:b(e.capabilities,e,t),query:g(e,t),queryRelated:m(e),queryTopFeatures:v(e),editing:w(e)}}function y(e){return{supportsCacheHint:u(e.advancedQueryCapabilities,"queryAnalytics")}}function c(e){const t=e.attachmentProperties,r={supportsName:!1,supportsSize:!1,supportsContentType:!1,supportsKeywords:!1,supportsExifInfo:!1,supportsCacheHint:u(e.advancedQueryCapabilities,"queryAttachments"),supportsResize:o(e,"supportsAttachmentsResizing",!1)};return t&&Array.isArray(t)&&t.forEach((e=>{const t=l[e.name];t&&(r[t]=!!e.isEnabled)})),r}function h(e){return{isVersioned:o(e,"isDataVersioned",!1),supportsAttachment:o(e,"hasAttachments",!1),supportsM:o(e,"hasM",!1),supportsZ:o(e,"hasZ",!1)}}function f(e){return{supportsAdvancedFieldProperties:o(e,"supportsFieldDescriptionProperty",!1)}}function b(e,t,r){const s=e?e.toLowerCase().split(",").map((e=>e.trim())):[],n=r?(0,i.Qc)(r):null,a=s.includes(null!=n&&"MapServer"===n.serverType?"data":"query"),l=s.includes("editing")&&!t.datesInUnknownTimezone;let p=l&&s.includes("create"),u=l&&s.includes("delete"),d=l&&s.includes("update");const y=s.includes("changetracking"),c=t.advancedQueryCapabilities;return l&&!(p||u||d)&&(p=u=d=!0),{supportsCalculate:o(t,"supportsCalculate",!1),supportsTruncate:o(t,"supportsTruncate",!1),supportsValidateSql:o(t,"supportsValidateSql",!1),supportsAdd:p,supportsDelete:u,supportsEditing:l,supportsChangeTracking:y,supportsQuery:a,supportsQueryAnalytics:o(c,"supportsQueryAnalytic",!1),supportsQueryAttachments:o(c,"supportsQueryAttachments",!1),supportsQueryTopFeatures:o(c,"supportsTopFeaturesQuery",!1),supportsResizeAttachments:o(t,"supportsAttachmentsResizing",!1),supportsSync:s.includes("sync"),supportsUpdate:d,supportsExceedsLimitStatistics:o(t,"supportsExceedsLimitStatistics",!1),supportsAsyncConvert3D:o(t,"supportsAsyncConvert3D",!1)}}function g(e,t){const r=e.advancedQueryCapabilities,a=e.ownershipBasedAccessControlForFeatures,l=e.archivingInfo,d=e.currentVersion,y=t?.includes("MapServer"),c=!y||d>=(0,s.Z)("mapserver-pbf-version-support"),h=(0,i.M8)(t),f=new Set((e.supportedQueryFormats??"").split(",").map((e=>e.toLowerCase().trim())));return{supportsStatistics:o(r,"supportsStatistics",e.supportsStatistics),supportsPercentileStatistics:o(r,"supportsPercentileStatistics",!1),supportsSpatialAggregationStatistics:o(r,"supportsSpatialAggregationStatistics",!1),supportedSpatialAggregationStatistics:p(r),supportsCentroid:o(r,"supportsReturningGeometryCentroid",!1),supportsDistance:o(r,"supportsQueryWithDistance",!1),supportsDistinct:o(r,"supportsDistinct",e.supportsAdvancedQueries),supportsExtent:o(r,"supportsReturningQueryExtent",!1),supportsGeometryProperties:o(r,"supportsReturningGeometryProperties",!1),supportsHavingClause:o(r,"supportsHavingClause",!1),supportsOrderBy:o(r,"supportsOrderBy",e.supportsAdvancedQueries),supportsPagination:o(r,"supportsPagination",!1),supportsQuantization:o(e,"supportsCoordinatesQuantization",!1),supportsQuantizationEditMode:o(e,"supportsQuantizationEditMode",!1),supportsQueryGeometry:o(e,"supportsReturningQueryGeometry",!1),supportsResultType:o(r,"supportsQueryWithResultType",!1),supportsMaxRecordCountFactor:o(r,"supportsMaxRecordCountFactor",!1),supportsSqlExpression:o(r,"supportsSqlExpression",!1),supportsStandardizedQueriesOnly:o(e,"useStandardizedQueries",!1),supportsTopFeaturesQuery:o(r,"supportsTopFeaturesQuery",!1),supportsQueryByAnonymous:o(a,"allowAnonymousToQuery",!0),supportsQueryByOthers:o(a,"allowOthersToQuery",!0),supportsHistoricMoment:o(l,"supportsQueryWithHistoricMoment",!1),supportsFormatPBF:c&&f.has("pbf"),supportsDisjointSpatialRelationship:o(r,"supportsDisjointSpatialRel",!1),supportsCacheHint:o(r,"supportsQueryWithCacheHint",!1)||u(r,"query"),supportsDefaultSpatialReference:o(r,"supportsDefaultSR",!1),supportsCompactGeometry:h,supportsFullTextSearch:o(r,"supportsFullTextSearch",!1),maxRecordCountFactor:n(e,"maxRecordCountFactor",void 0),maxRecordCount:n(e,"maxRecordCount",void 0),standardMaxRecordCount:n(e,"standardMaxRecordCount",void 0),tileMaxRecordCount:n(e,"tileMaxRecordCount",void 0)}}function m(e){const t=e.advancedQueryCapabilities,r=o(t,"supportsAdvancedQueryRelated",!1);return{supportsPagination:o(t,"supportsQueryRelatedPagination",!1),supportsCount:r,supportsOrderBy:r,supportsCacheHint:u(t,"queryRelated")}}function v(e){return{supportsCacheHint:u(e.advancedQueryCapabilities,"queryTopFilter")}}function w(e){const t=e.ownershipBasedAccessControlForFeatures,r=e?e.advancedEditingCapabilities:void 0;return{supportsGeometryUpdate:o(e,"allowGeometryUpdates",!0),supportsGlobalId:o(e,"supportsApplyEditsWithGlobalIds",!1),supportsReturnServiceEditsInSourceSpatialReference:o(e,"supportsReturnServiceEditsInSourceSR",!1),supportsRollbackOnFailure:o(e,"supportsRollbackOnFailureParameter",!1),supportsUpdateWithoutM:o(e,"allowUpdateWithoutMValues",!1),supportsUploadWithItemId:o(e,"supportsAttachmentsByUploadId",!1),supportsDeleteByAnonymous:o(t,"allowAnonymousToDelete",!0),supportsDeleteByOthers:o(t,"allowOthersToDelete",!0),supportsUpdateByAnonymous:o(t,"allowAnonymousToUpdate",!0),supportsUpdateByOthers:o(t,"allowOthersToUpdate",!0),supportsAsyncApplyEdits:o(r,"supportsAsyncApplyEdits",!1),zDefault:n(e,"zDefault",void 0)}}},58333:(e,t,r)=>{r.d(t,{ET:()=>o,I4:()=>i,eG:()=>l,lF:()=>n,lj:()=>u,qP:()=>a,wW:()=>p});const s=[252,146,31,255],i={type:"esriSMS",style:"esriSMSCircle",size:6,color:s,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:s},n={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},p={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},u={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2118,5732],{84552:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(43697),i=r(2368),s=r(96674),o=r(35463),l=r(5600),a=(r(75215),r(67676),r(80442),r(36030)),u=r(52011),p=r(78981);let d=class extends((0,i.J)(s.wq)){constructor(e){super(e),this.unit="milliseconds",this.value=0}toMilliseconds(){return(0,o.rJ)(this.value,this.unit,"milliseconds")}};(0,n._)([(0,a.J)(p.v,{nonNullable:!0})],d.prototype,"unit",void 0),(0,n._)([(0,l.Cb)({type:Number,json:{write:!0},nonNullable:!0})],d.prototype,"value",void 0),d=(0,n._)([(0,u.j)("esri.TimeInterval")],d);const c=d},5732:(e,t,r)=>{r.d(t,{c:()=>n,g:()=>i});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function i(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}},60437:(e,t,r)=>{r.d(t,{G_:()=>w,HH:()=>o,JR:()=>f,TC:()=>l,Tn:()=>d,Ue:()=>i,al:()=>s,bZ:()=>y,cS:()=>h,dp:()=>u,fS:()=>g,is:()=>m,op:()=>p,pp:()=>a,t8:()=>c});var n=r(6570);function i(e=b){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function s(e,t,r,n,s,o,l=i()){return l[0]=e,l[1]=t,l[2]=r,l[3]=n,l[4]=s,l[5]=o,l}function o(e,t){const r=isFinite(e[2])||isFinite(e[5]);return new n.Z(r?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function a(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function u(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function p(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function d(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function c(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function h(e){return e?c(e,w):i(w)}function f(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function y(e,t,r,n,i){return e[0]=t,e[1]=r,e[2]=Number.NEGATIVE_INFINITY,e[3]=n,e[4]=i,e[5]=Number.POSITIVE_INFINITY,e}function m(e){return 6===e.length}function g(e,t,r){if(null==e||null==t)return e===t;if(!m(e)||!m(t))return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}r(24470);const w=[1/0,1/0,1/0,-1/0,-1/0,-1/0],b=[0,0,0,0,0,0];i()},88068:(e,t,r)=>{r.r(t),r.d(t,{default:()=>U});var n=r(43697),i=(r(66577),r(51773)),s=(r(16050),r(12501),r(28756),r(92271),r(72529),r(5499),r(84382),r(81571),r(91423),r(32400)),o=r(16453),l=r(5600),a=(r(75215),r(67676),r(80442),r(52011)),u=r(86973),p=r(87085),d=r(20102),c=r(83379),h=r(16467),f=r(74889),y=r(82971);let m=class extends c.Z{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=>f.Z.fromJSON(e)))}queryFeaturesJSON(e,t={}){const r=this.getSource();return this.load(t).then((()=>(0,h.yN)(r,e,t)))}queryObjectIds(e,t={}){return null}serviceSupportsSpatialReference(e){return!(!e.isWGS84&&!e.isWebMercator&&!this.featureDefinition.supportedCrs[e.wkid])}_conformsToType(e,t){const r=new RegExp(`^${t}$`,"i");return e.conformsTo.some((e=>r.test(e)))??!1}_getCapabilities(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!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,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:!1,supportsExceedsLimitStatistics:!1,supportsAsyncConvert3D:!1},query:{maxRecordCount:t,maxRecordCountFactor:void 0,standardMaxRecordCount:void 0,supportsCacheHint:!1,supportsCentroid:!1,supportsDisjointSpatialRelationship:!1,supportsDistance:!1,supportsDistinct:!1,supportsExtent:!1,supportsFormatPBF:!1,supportsGeometryProperties:!1,supportsHavingClause:!1,supportsHistoricMoment:!1,supportsMaxRecordCountFactor:!1,supportsOrderBy:!1,supportsPagination:!1,supportsPercentileStatistics:!1,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryByAnonymous:!1,supportsQueryByOthers:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsStandardizedQueriesOnly:!1,supportsTopFeaturesQuery:!1,supportsStatistics:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,supportsSqlExpression:!1,tileMaxRecordCount:void 0},queryRelated:{supportsCount:!1,supportsOrderBy:!1,supportsPagination:!1,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},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??h.$9,r=(0,h.d)(t);return null==r?y.Z.WGS84:new y.Z({wkid:r})}_getSupportedSpatialReferences(e,t){const r="#/crs",n=e.crs??[h.$9],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:s,fields:o,geometryType:l,hasZ:a,objectIdField:p,timeInfo:c,url:f}=e,y={fields:o?.map((e=>e.toJSON())),geometryType:u.P.toJSON(l),hasZ:a??!1,objectIdField:p,timeInfo:c?.toJSON()},m={apiKey:n,customParameters:s,signal:r},g=await(0,h.gp)(f,m),[w,b]=await Promise.all([(0,h.G4)(g,m),(0,h.j)(g,m)]);if(!this._conformsToType(w,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/geojson"))throw new d.Z("ogc-feature-layer:no-geojson-support","Server does not support geojson");const v=b.collections.find((e=>e.id===i));if(!v)throw new d.Z("ogc-feature-layer:collection-not-found","Server does not contain the named collection");const _=this._conformsToType(w,"http://www.opengis.net/spec/ogcapi-features-1/1.0/conf/oas30")?await(0,h.eS)(g,m):null,F=await(0,h.w9)(v,y,m),T=this._getMaxRecordCount(_),x=this._getCapabilities(F.hasZ,T),I=this._getStorageSpatialReference(v).toJSON(),C=this._getSupportedSpatialReferences(v,b),S=new RegExp(`^${h.Lu}`,"i"),R={};for(const e of C){const t=(0,h.d)(e);null!=t&&(R[t]||(R[t]=e.replace(S,"")))}this.featureDefinition={capabilities:x,collection:v,layerDefinition:F,spatialReference:I,supportedCrs:R}}};(0,n._)([(0,l.Cb)()],m.prototype,"featureDefinition",void 0),(0,n._)([(0,l.Cb)({constructOnly:!0})],m.prototype,"layer",void 0),(0,n._)([(0,l.Cb)()],m.prototype,"type",void 0),m=(0,n._)([(0,a.j)("esri.layers.graphics.sources.OGCFeatureSource")],m);var g=r(54295),w=r(71612),b=r(17017),v=r(69637),_=r(6404),F=r(38009),T=r(68825),x=r(16859),I=r(34760),C=r(72965),S=r(28294),R=r(21506),j=r(16451),Z=r(1231),N=r(53518),E=r(69165),M=r(54306),O=r(30707),P=r(14165),D=r(32163),G=r(6570);const q=(0,N.v)();let L=class extends((0,g.V)((0,b.N)((0,_.M)((0,v.b)((0,w.h)((0,T.c)((0,S.n)((0,C.M)((0,F.q)((0,x.I)((0,I.Q)((0,o.R)(p.Z))))))))))))){constructor(e){super(e),this.capabilities=null,this.collectionId=null,this.copyright=null,this.definitionExpression=null,this.description=null,this.displayField=null,this.elevationInfo=null,this.fields=null,this.fieldsIndex=null,this.fullExtent=null,this.geometryType=null,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 m({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,E.YN)(e,this.fieldsIndex),this._set("renderer",e)}on(e,t){return super.on(e,t)}createPopupTemplate(e){return(0,D.eZ)(this,e)}createQuery(){return new P.Z}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(P.Z.from(e)||this.createQuery(),t))).then((e=>(e?.features?.forEach((e=>{e.layer=e.sourceLayer=this})),e)))}serviceSupportsSpatialReference(e){return this.source?.serviceSupportsSpatialReference(e)??!1}async _fetchService(e){await this.source.load(e),this.read(this.source.featureDefinition,{origin:"service"}),(0,E.YN)(this.renderer,this.fieldsIndex),(0,E.UF)(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._)([(0,l.Cb)({readOnly:!0,json:{origins:{service:{read:!0}}}})],L.prototype,"capabilities",void 0),(0,n._)([(0,l.Cb)({type:String,json:{write:!0}})],L.prototype,"collectionId",void 0),(0,n._)([(0,l.Cb)({type:String})],L.prototype,"copyright",void 0),(0,n._)([(0,l.Cb)({readOnly:!0})],L.prototype,"defaultPopupTemplate",null),(0,n._)([(0,l.Cb)({type:String})],L.prototype,"definitionExpression",void 0),(0,n._)([(0,l.Cb)({readOnly:!0,type:String,json:{origins:{service:{name:"collection.description"}}}})],L.prototype,"description",void 0),(0,n._)([(0,l.Cb)({type:String})],L.prototype,"displayField",void 0),(0,n._)([(0,l.Cb)({type:Number})],L.prototype,"effectiveMaxRecordCount",null),(0,n._)([(0,l.Cb)(R.PV)],L.prototype,"elevationInfo",void 0),(0,n._)([(0,l.Cb)({type:[Z.Z],json:{origins:{service:{name:"layerDefinition.fields"}}}})],L.prototype,"fields",void 0),(0,n._)([(0,l.Cb)(q.fieldsIndex)],L.prototype,"fieldsIndex",void 0),(0,n._)([(0,l.Cb)({readOnly:!0,type:G.Z,json:{origins:{service:{name:"layerDefinition.extent"}}}})],L.prototype,"fullExtent",void 0),(0,n._)([(0,l.Cb)({type:u.M.apiValues,json:{origins:{service:{name:"layerDefinition.geometryType",read:{reader:u.M.read}}}}})],L.prototype,"geometryType",void 0),(0,n._)([(0,l.Cb)({type:Boolean,json:{origins:{service:{name:"layerDefinition.hasZ"}}}})],L.prototype,"hasZ",void 0),(0,n._)([(0,l.Cb)({type:Boolean,readOnly:!0})],L.prototype,"isTable",null),(0,n._)([(0,l.Cb)({type:[M.Z],json:{origins:{"web-document":{name:"layerDefinition.drawingInfo.labelingInfo",read:{reader:O.r},write:!0}}}})],L.prototype,"labelingInfo",void 0),(0,n._)([(0,l.Cb)(R.iR)],L.prototype,"labelsVisible",void 0),(0,n._)([(0,l.Cb)(R.rn)],L.prototype,"legendEnabled",void 0),(0,n._)([(0,l.Cb)({type:Number})],L.prototype,"maxRecordCount",void 0),(0,n._)([(0,l.Cb)({type:String,json:{origins:{service:{name:"layerDefinition.objectIdField"}}}})],L.prototype,"objectIdField",void 0),(0,n._)([(0,l.Cb)({type:["OGCFeatureLayer"]})],L.prototype,"operationalLayerType",void 0),(0,n._)([(0,l.Cb)(R.C_)],L.prototype,"popupEnabled",void 0),(0,n._)([(0,l.Cb)({type:i.Z,json:{name:"popupInfo",write:!0}})],L.prototype,"popupTemplate",void 0),(0,n._)([(0,l.Cb)({types:s.A,json:{origins:{service:{name:"layerDefinition.drawingInfo.renderer",write:!1},"web-scene":{types:s.o,name:"layerDefinition.drawingInfo.renderer",write:!0}},name:"layerDefinition.drawingInfo.renderer",write:!0}})],L.prototype,"renderer",null),(0,n._)([(0,l.Cb)(R.YI)],L.prototype,"screenSizePerspectiveEnabled",void 0),(0,n._)([(0,l.Cb)({readOnly:!0})],L.prototype,"source",void 0),(0,n._)([(0,l.Cb)({readOnly:!0,type:y.Z,json:{origins:{service:{read:!0}}}})],L.prototype,"spatialReference",void 0),(0,n._)([(0,l.Cb)({type:String,json:{write:{enabled:!0,ignoreOrigin:!0,isRequired:!0},origins:{service:{name:"collection.title"}}}})],L.prototype,"title",void 0),(0,n._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],L.prototype,"type",void 0),(0,n._)([(0,l.Cb)({type:String,readOnly:!0})],L.prototype,"typeIdField",void 0),(0,n._)([(0,l.Cb)({type:[j.Z]})],L.prototype,"types",void 0),(0,n._)([(0,l.Cb)(R.HQ)],L.prototype,"url",void 0),L=(0,n._)([(0,a.j)("esri.layers.OGCFeatureLayer")],L);const U=L},70272:(e,t,r)=>{r.d(t,{S6:()=>i,nd:()=>s,u_:()=>n});class n{constructor(e=null,t={},r,n){this.geometry=e,this.attributes=t,this.centroid=r,this.objectId=n,this.displayId=0,this.geohashX=0,this.geohashY=0}weakClone(){const e=new n(this.geometry,this.attributes,this.centroid,this.objectId);return e.displayId=this.displayId,e.geohashX=this.geohashX,e.geohashY=this.geohashY,e}}function i(e){return!!e.geometry?.coords?.length}class s extends n{}},44876:(e,t,r)=>{r.d(t,{Z:()=>n});class n{constructor(){this.objectIdFieldName=null,this.globalIdFieldName=null,this.geohashFieldName=null,this.geometryProperties=null,this.geometryType=null,this.spatialReference=null,this.hasZ=!1,this.hasM=!1,this.features=[],this.fields=[],this.transform=null,this.exceededTransferLimit=!1,this.uniqueIdField=null,this.queryGeometryType=null,this.queryGeometry=null}weakClone(){const e=new n;return e.objectIdFieldName=this.objectIdFieldName,e.globalIdFieldName=this.globalIdFieldName,e.geohashFieldName=this.geohashFieldName,e.geometryProperties=this.geometryProperties,e.geometryType=this.geometryType,e.spatialReference=this.spatialReference,e.hasZ=this.hasZ,e.hasM=this.hasM,e.features=this.features,e.fields=this.fields,e.transform=this.transform,e.exceededTransferLimit=this.exceededTransferLimit,e.uniqueIdField=this.uniqueIdField,e.queryGeometry=this.queryGeometry,e.queryGeometryType=this.queryGeometryType,e}}},5428:(e,t,r)=>{r.d(t,{Z:()=>n});class n{constructor(e=[],t=[],r=!1){this.lengths=e??[],this.coords=t??[],this.hasIndeterminateRingOrder=r}static fromRect(e){const[t,r,i,s]=e,o=i-t,l=s-r;return new n([5],[t,r,o,0,0,l,-o,0,0,-l])}get isPoint(){return 0===this.lengths.length}get maxLength(){return Math.max(...this.lengths)}get size(){return this.lengths.reduce(((e,t)=>e+t))}forEachVertex(e){let t=0;this.lengths.length||e(this.coords[0],this.coords[1]);for(let r=0;r<this.lengths.length;r++){const n=this.lengths[r];for(let r=0;r<n;r++)e(this.coords[2*(r+t)],this.coords[2*(r+t)+1]);t+=n}}clone(e){return e?(e.set(this.coords),new n(this.lengths.slice(),e,this.hasIndeterminateRingOrder)):new n(this.lengths.slice(),this.coords.slice(),this.hasIndeterminateRingOrder)}}},61159:(e,t,r)=>{r.d(t,{g:()=>n});const n={supportsStatistics:!0,supportsPercentileStatistics:!0,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsCentroid:!0,supportsCacheHint:!1,supportsDistance:!0,supportsDistinct:!0,supportsExtent:!0,supportsGeometryProperties:!1,supportsHavingClause:!0,supportsOrderBy:!0,supportsPagination:!0,supportsQuantization:!0,supportsQuantizationEditMode:!1,supportsQueryGeometry:!0,supportsResultType:!1,supportsSqlExpression:!0,supportsMaxRecordCountFactor:!1,supportsStandardizedQueriesOnly:!0,supportsTopFeaturesQuery:!1,supportsQueryByAnonymous:!0,supportsQueryByOthers:!0,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!0,supportsDefaultSpatialReference:!1,supportsFullTextSearch:!1,supportsCompactGeometry:!1,maxRecordCountFactor:void 0,maxRecordCount:void 0,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}},98732:(e,t,r)=>{r.d(t,{$:()=>re,$g:()=>ne,EI:()=>J,GH:()=>k,IN:()=>_,Iv:()=>O,J6:()=>D,Jd:()=>v,Nh:()=>W,RZ:()=>$,Uy:()=>L,XA:()=>B,Yn:()=>A,cn:()=>H,dd:()=>M,di:()=>Q,eG:()=>q,fQ:()=>T,hY:()=>ie,h_:()=>Y,lM:()=>K,lz:()=>oe,zj:()=>X});var n=r(20102),i=r(92604),s=r(70586),o=r(60437),l=r(24470),a=r(33955),u=r(70272),p=r(44876),d=r(5428);function c(e,t){return e?t?4:3:t?3:2}const h=i.Z.getLogger("esri.layers.graphics.featureConversionUtils"),f={esriGeometryPoint:0,esriGeometryPolyline:2,esriGeometryPolygon:3,esriGeometryMultipoint:0,esriGeometryEnvelope:0},y=(e,t,r,n,i,s)=>{e[r]=i,e[r+1]=s},m=(e,t,r,n,i,s)=>{e[r]=i,e[r+1]=s,e[r+2]=t[n+2]},g=(e,t,r,n,i,s)=>{e[r]=i,e[r+1]=s,e[r+2]=t[n+3]},w=(e,t,r,n,i,s)=>{e[r]=i,e[r+1]=s,e[r+2]=t[n+2],e[r+3]=t[n+3]};function b(e,t,r,n){if(e){if(r)return t&&n?w:m;if(t&&n)return g}else if(t&&n)return m;return y}function v({scale:e,translate:t},r){return Math.round((r-t[0])/e[0])}function _({scale:e,translate:t},r){return Math.round((t[1]-r)/e[1])}function F({scale:e,translate:t},r,n){return r*e[n]+t[n]}function T(e,t,r){return e?t?r?Z(e):C(e):r?R(e):x(e):null}function x(e){const t=e.coords;return{x:t[0],y:t[1]}}function I(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e}function C(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2]}}function S(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e}function R(e){const t=e.coords;return{x:t[0],y:t[1],m:t[2]}}function j(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.m,e}function Z(e){const t=e.coords;return{x:t[0],y:t[1],z:t[2],m:t[3]}}function N(e,t){return e.coords[0]=t.x,e.coords[1]=t.y,e.coords[2]=t.z,e.coords[3]=t.m,e}function E(e,t){return e&&t?N:e?S:t?j:I}function M(e,t,r=E(null!=t.z,null!=t.m)){return r(e,t)}function O(e,t,r){if(null==e)return null;const n=c(t,r),i=[];for(let t=0;t<e.coords.length;t+=n){const r=[];for(let i=0;i<n;i++)r.push(e.coords[t+i]);i.push(r)}return t?r?{points:i,hasZ:t,hasM:r}:{points:i,hasZ:t}:r?{points:i,hasM:r}:{points:i}}function P(e,t,r=c(t.hasZ,t.hasM)){e.lengths[0]=t.points.length;const n=e.coords;let i=0;for(const e of t.points)for(let t=0;t<r;t++)n[i++]=e[t];return e}function D(e,t,r){if(!e)return null;const n=c(t,r),{coords:i,lengths:s}=e,o=[];let l=0;for(const e of s){const t=[];for(let r=0;r<e;r++){const e=[];for(let t=0;t<n;t++)e.push(i[l++]);t.push(e)}o.push(t)}return t?r?{paths:o,hasZ:t,hasM:r}:{paths:o,hasZ:t}:r?{paths:o,hasM:r}:{paths:o}}function G(e,t,r=c(t.hasZ,t.hasM)){const{lengths:n,coords:i}=e;let s=0;for(const e of t.paths){for(const t of e)for(let e=0;e<r;e++)i[s++]=t[e];n.push(e.length)}return e}function q(e,t,r){if(!e)return null;const n=c(t,r),{coords:i,lengths:s}=e,o=[];let l=0;for(const e of s){const t=[];for(let r=0;r<e;r++){const e=[];for(let t=0;t<n;t++)e.push(i[l++]);t.push(e)}o.push(t)}return t?r?{rings:o,hasZ:t,hasM:r}:{rings:o,hasZ:t}:r?{rings:o,hasM:r}:{rings:o}}function L(e,t,r=t.hasZ,n=t.hasM){return function(e,t,r,n){const i=c(r,n),{lengths:s,coords:o}=e;let l=0;le(e);for(const e of t){for(const t of e)for(let e=0;e<i;e++)o[l++]=t[e];s.push(e.length)}return e}(e,t.rings,r,n)}const U=[],z=[];function B(e,t,r,n,i){U[0]=e;const[s]=A(z,U,t,r,n,i);return ae(U),ae(z),s}function A(e,t,r,i,s,o){if(ae(e),!r){for(const r of t){const t=o?r.attributes[o]:void 0;e.push(new u.u_(null,r.attributes,null,t))}return e}switch(r){case"esriGeometryPoint":return function(e,t,r,n,i){const s=E(r,n);for(const{geometry:r,attributes:n}of t){const t=null!=r?s(new d.Z,r):null;e.push(new u.u_(t,n,null,i?n[i]:void 0))}return e}(e,t,i,s,o);case"esriGeometryMultipoint":return function(e,t,r,n,i){const s=c(r,n);for(const{geometry:r,attributes:n}of t){const t=null!=r?P(new d.Z,r,s):null;e.push(new u.u_(t,n,null,i?n[i]:void 0))}return e}(e,t,i,s,o);case"esriGeometryPolyline":return function(e,t,r,n,i){const s=c(r,n);for(const{geometry:r,attributes:n}of t){const t=null!=r?G(new d.Z,r,s):null;e.push(new u.u_(t,n,null,i?n[i]:void 0))}return e}(e,t,i,s,o);case"esriGeometryPolygon":return function(e,t,r,n,i){for(const{geometry:s,centroid:o,attributes:l}of t){const t=null!=s?L(new d.Z,s,r,n):null,a=i?l[i]:void 0;null!=o?e.push(new u.u_(t,l,I(new d.Z,o),a)):e.push(new u.u_(t,l,null,a))}return e}(e,t,i,s,o);default:h.error("convertToFeatureSet:unknown-geometry",new n.Z(`Unable to parse unknown geometry type '${r}'`)),ae(e)}return e}function J(e,t,r,n){z[0]=e,V(U,z,t,r,n);const i=U[0];return ae(U),ae(z),i}function k(e,t,r){if(null==e)return null;const i=new d.Z;return"hasZ"in e&&null==t&&(t=e.hasZ),"hasM"in e&&null==r&&(r=e.hasM),(0,a.wp)(e)?E(null!=t?t:null!=e.z,null!=r?r:null!=e.m)(i,e):(0,a.oU)(e)?L(i,e,t,r):(0,a.l9)(e)?G(i,e,c(t,r)):(0,a.aW)(e)?P(i,e,c(t,r)):void h.error("convertFromGeometry:unknown-geometry",new n.Z(`Unable to parse unknown geometry type '${e}'`))}function Q(e,t,r,i){const s=e&&("coords"in e?e:e.geometry);if(null==s)return null;switch(t){case"esriGeometryPoint":{let e=x;return r&&i?e=Z:r?e=C:i&&(e=R),e(s)}case"esriGeometryMultipoint":return O(s,r,i);case"esriGeometryPolyline":return D(s,r,i);case"esriGeometryPolygon":return q(s,r,i);default:return h.error("convertToGeometry:unknown-geometry",new n.Z(`Unable to parse unknown geometry type '${t}'`)),null}}function V(e,t,r,i,s){if(ae(e),null==r)return function(e,t){for(const r of t)e.push({attributes:r.attributes});return e}(e,t);switch(r){case"esriGeometryPoint":return function(e,t,r,n){let i=x;r&&n?i=Z:r?i=C:n&&(i=R);for(const r of t){const{geometry:t,attributes:n}=r,s=null!=t?i(t):null;e.push({attributes:n,geometry:s})}return e}(e,t,i,s);case"esriGeometryMultipoint":return function(e,t,r,n){for(const{geometry:i,attributes:s}of t)e.push({attributes:s,geometry:null!=i?O(i,r,n):null});return e}(e,t,i,s);case"esriGeometryPolyline":return function(e,t,r,n){for(const{geometry:i,attributes:s}of t)e.push({attributes:s,geometry:null!=i?D(i,r,n):null});return e}(e,t,i,s);case"esriGeometryPolygon":return function(e,t,r,n){for(const{geometry:i,attributes:s,centroid:o}of t){const t=null!=i?q(i,r,n):null;if(null!=o){const r=x(o);e.push({attributes:s,centroid:r,geometry:t})}else e.push({attributes:s,geometry:t})}return e}(e,t,i,s);default:h.error("convertToFeatureSet:unknown-geometry",new n.Z(`Unable to parse unknown geometry type '${r}'`))}return e}function H(e){const{objectIdFieldName:t,spatialReference:r,transform:n,fields:i,hasM:s,hasZ:o,features:l,geometryType:a,exceededTransferLimit:u,uniqueIdField:p,queryGeometry:d,queryGeometryType:c}=e,h={features:V([],l,a,o,s),fields:i,geometryType:a,objectIdFieldName:t,spatialReference:r,uniqueIdField:p,queryGeometry:Q(d,c,!1,!1)};return n&&(h.transform=n),u&&(h.exceededTransferLimit=u),s&&(h.hasM=s),o&&(h.hasZ=o),h}function Y(e,t){const r=new p.Z,{hasM:i,hasZ:s,features:o,objectIdFieldName:l,spatialReference:a,geometryType:u,exceededTransferLimit:d,transform:c,fields:f}=e;return f&&(r.fields=f),r.geometryType=u??null,r.objectIdFieldName=l??t??null,r.spatialReference=a??null,r.objectIdFieldName?(o&&A(r.features,o,u,s,i,r.objectIdFieldName),d&&(r.exceededTransferLimit=d),i&&(r.hasM=i),s&&(r.hasZ=s),c&&(r.transform=c),r):(h.error(new n.Z("optimized-features:invalid-objectIdFieldName","objectIdFieldName is missing")),r)}function K(e){const{transform:t,features:r,hasM:n,hasZ:i}=e;if(!t)return e;for(const e of r)null!=e.geometry&&ne(e.geometry,e.geometry,n,i,t),null!=e.centroid&&ne(e.centroid,e.centroid,n,i,t);return e.transform=null,e}function $(e,t){const{geometryType:r,features:n,hasM:i,hasZ:s}=t;if(!e)return t;for(let t=0;t<n.length;t++){const o=n[t],l=o.weakClone();l.geometry=new d.Z,W(l.geometry,o.geometry,i,s,r,e),o.centroid&&(l.centroid=new d.Z,W(l.centroid,o.centroid,i,s,"esriGeometryPoint",e)),n[t]=l}return t.transform=e,t}function W(e,t,r,n,i,s,o=r,l=n){if(le(e),!t?.coords.length)return null;const a=f[i],{coords:u,lengths:p}=t,d=c(r,n),h=c(r&&o,n&&l),y=b(r,n,o,l);if(!p.length)return y(e.coords,u,0,0,v(s,u[0]),_(s,u[1])),le(e,d,0),e;let m,g,w,F,T=0,x=0,I=x;for(const t of p){if(t<a)continue;let r=0;x=I,w=m=v(s,u[T]),F=g=_(s,u[T+1]),y(e.coords,u,x,T,w,F),r++,T+=d,x+=h;for(let n=1;n<t;n++,T+=d)w=v(s,u[T]),F=_(s,u[T+1]),w===m&&F===g||(y(e.coords,u,x,T,w-m,F-g),x+=h,r++,m=w,g=F);r>=a&&(e.lengths.push(r),I=x)}return ae(e.coords,I),e.coords.length?e:null}function X(e,t,r,n,i,s,o=r,l=n){if(le(e),!t?.coords.length)return null;const a=f[i],{coords:u,lengths:p}=t,d=c(r,n),h=c(r&&o,n&&l),y=b(r,n,o,l);if(!p.length)return y(e.coords,u,0,0,u[0],u[1]),le(e,d,0),e;let m=0;const g=s*s;for(const t of p){if(t<a){m+=t*d;continue}const r=e.coords.length/h,n=m,i=m+(t-1)*d;y(e.coords,u,e.coords.length,n,u[n],u[n+1]),te(e.coords,u,d,g,y,n,i),y(e.coords,u,e.coords.length,i,u[i],u[i+1]);const s=e.coords.length/h-r;s>=a?e.lengths.push(s):ae(e.coords,r*h),m+=t*d}return e.coords.length?e:null}function ee(e,t,r,n){const i=e[t],s=e[t+1],o=e[r],l=e[r+1],a=e[n],u=e[n+1];let p=o,d=l,c=a-p,h=u-d;if(0!==c||0!==h){const e=((i-p)*c+(s-d)*h)/(c*c+h*h);e>1?(p=a,d=u):e>0&&(p+=c*e,d+=h*e)}return c=i-p,h=s-d,c*c+h*h}function te(e,t,r,n,i,s,o){let l,a=n,u=0;for(let e=s+r;e<o;e+=r)l=ee(t,e,s,o),l>a&&(u=e,a=l);a>n&&(u-s>r&&te(e,t,r,n,i,s,u),i(e,t,e.length,u,t[u],t[u+1]),o-u>r&&te(e,t,r,n,i,u,o))}function re(e,t,r,n){if(!t?.coords?.length)return null;const i=c(r,n);let s=Number.POSITIVE_INFINITY,a=Number.POSITIVE_INFINITY,u=Number.NEGATIVE_INFINITY,p=Number.NEGATIVE_INFINITY;if(t&&t.coords){const e=t.coords;for(let t=0;t<e.length;t+=i){const r=e[t],n=e[t+1];s=Math.min(s,r),u=Math.max(u,r),a=Math.min(a,n),p=Math.max(p,n)}}return(0,o.is)(e)?(0,o.bZ)(e,s,a,u,p):(0,l.al)(s,a,u,p,e),e}function ne(e,t,r,n,i){const{coords:o,lengths:l}=t,a=c(r,n);if(!o.length)return e!==t&&le(e),e;(0,s.O3)(i);const{originPosition:u,scale:p,translate:d}=i,h=ue;h.originPosition=u;const f=h.scale;f[0]=p[0]??1,f[1]=-(p[1]??1),f[2]=p[2]??1,f[3]=p[3]??1;const y=h.translate;if(y[0]=d[0]??0,y[1]=d[1]??0,y[2]=d[2]??0,y[3]=d[3]??0,!l.length){for(let t=0;t<a;++t)e.coords[t]=F(h,o[t],t);return e!==t&&le(e,a,0),e}let m=0;for(let t=0;t<l.length;t++){const r=l[t];e.lengths[t]=r;for(let t=0;t<a;++t)e.coords[m+t]=F(h,o[m+t],t);let n=e.coords[m],i=e.coords[m+1];m+=a;for(let t=1;t<r;t++,m+=a){n+=o[m]*f[0],i+=o[m+1]*f[1],e.coords[m]=n,e.coords[m+1]=i;for(let t=2;t<a;++t)e.coords[m+t]=F(h,o[m+t],t)}}return e!==t&&le(e,o.length,l.length),e}function ie(e,t,r,n,i,s){if(le(e),e.lengths.push(...t.lengths),r===i&&n===s)for(let r=0;r<t.coords.length;r++)e.coords.push(t.coords[r]);else{const o=c(r,n),l=b(r,n,i,s),a=t.coords;for(let t=0;t<a.length;t+=o)l(e.coords,a,e.coords.length,t,a[t],a[t+1])}return e}function se(e,t,r,n){let i=0,s=e[n*t],o=e[n*(t+1)];for(let l=1;l<r;l++){const r=s+e[n*(t+l)],a=o+e[n*(t+l)+1],u=(r-s)*(a+o);s=r,o=a,i+=u}return.5*i}function oe(e,t){const{coords:r,lengths:n}=e;let i=0,s=0;for(let e=0;e<n.length;e++){const o=n[e];s+=se(r,i,o,t),i+=o}return Math.abs(s)}function le(e,t=0,r=0){ae(e.lengths,r),ae(e.coords,t)}function ae(e,t=0){e.length!==t&&(e.length=t)}const ue={originPosition:"lowerLeft",scale:[1,1,1,1],translate:[0,0,0,0]}},54295:(e,t,r)=>{r.d(t,{V:()=>o});var n=r(43697),i=r(5600),s=(r(75215),r(67676),r(80442),r(52011));const o=e=>{let t=class extends e{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._)([(0,i.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,n._)([(0,s.j)("esri.layers.mixins.APIKeyMixin")],t),t}},17017:(e,t,r)=>{r.d(t,{N:()=>o});var n=r(43697),i=r(5600),s=(r(75215),r(67676),r(80442),r(52011));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,n._)([(0,i.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,n._)([(0,s.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},69637:(e,t,r)=>{r.d(t,{b:()=>S});var n,i=r(43697),s=r(5600),o=(r(75215),r(67676),r(80442),r(52011)),l=r(20102),a=r(96674),u=r(78286),p=r(72746),d=r(66577),c=r(92835),h=r(35454),f=r(22974),y=r(14165);const m=new h.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),g=new h.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let w=n=class extends a.wq{constructor(e){super(e),this.where=null,this.geometry=null,this.spatialRelationship="intersects",this.distance=void 0,this.objectIds=null,this.units=null,this.timeExtent=null}createQuery(e={}){const{where:t,geometry:r,spatialRelationship:n,timeExtent:i,objectIds:s,units:o,distance:l}=this;return new y.Z({geometry:(0,f.d9)(r),objectIds:(0,f.d9)(s),spatialRelationship:n,timeExtent:(0,f.d9)(i),where:t,units:o,distance:l,...e})}clone(){const{where:e,geometry:t,spatialRelationship:r,timeExtent:i,objectIds:s,units:o,distance:l}=this;return new n({geometry:(0,f.d9)(t),objectIds:(0,f.d9)(s),spatialRelationship:r,timeExtent:(0,f.d9)(i),where:e,units:o,distance:l})}};(0,i._)([(0,s.Cb)({type:String,json:{write:!0}})],w.prototype,"where",void 0),(0,i._)([(0,s.Cb)({types:d.qM,json:{write:!0}})],w.prototype,"geometry",void 0),(0,i._)([(0,s.Cb)({type:m.apiValues,json:{name:"spatialRel",read:{reader:m.read},write:{allowNull:!1,writer:m.write,overridePolicy(){return{enabled:null!=this.geometry}}}}})],w.prototype,"spatialRelationship",void 0),(0,i._)([(0,s.Cb)({type:Number,json:{write:{overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],w.prototype,"distance",void 0),(0,i._)([(0,s.Cb)({type:[Number],json:{write:!0}})],w.prototype,"objectIds",void 0),(0,i._)([(0,s.Cb)({type:g.apiValues,json:{read:g.read,write:{writer:g.write,overridePolicy(e){return{enabled:null!=e&&null!=this.geometry}}}}})],w.prototype,"units",void 0),(0,i._)([(0,s.Cb)({type:c.Z,json:{write:!0}})],w.prototype,"timeExtent",void 0),w=n=(0,i._)([(0,o.j)("esri.layers.support.FeatureFilter")],w);const b=w;var v;const _={read:{reader:p.ij},write:{writer:p.cW,overridePolicy(){return{allowNull:null!=this.excludedEffect,isRequired:null==this.excludedEffect}}}},F={read:{reader:p.ij},write:{writer:p.cW,overridePolicy(){return{allowNull:null!=this.includedEffect,isRequired:null==this.includedEffect}}}},T={name:"showExcludedLabels",default:!0};let x=v=class extends a.wq{constructor(e){super(e),this.filter=null,this.includedEffect=null,this.excludedEffect=null,this.excludedLabelsVisible=!1}write(e,t){const r=super.write(e,t);if(t?.origin){if(r.filter){const e=Object.keys(r.filter);if(e.length>1||"where"!==e[0])return t.messages?.push(new l.Z("web-document-write:unsupported-feature-effect","Invalid feature effect 'filter'. A filter can only contain a 'where' property",{layer:t.layer,effect:this})),null}if("showExcludedLabels"in r)return t.messages?.push(new l.Z("web-document-write:unsupported-feature-effect","Invalid value for property 'excludedLabelsVisible' which should always be 'true'",{layer:t.layer,effect:this})),null}return r}clone(){return new v({filter:null!=this.filter?this.filter.clone():null,includedEffect:this.includedEffect,excludedEffect:this.excludedEffect,excludedLabelsVisible:this.excludedLabelsVisible})}};(0,i._)([(0,s.Cb)({type:b,json:{write:{allowNull:!0,writer(e,t,r,n){const i=e?.write({},n);i&&0!==Object.keys(i).length?(0,u.RB)(r,i,t):(0,u.RB)(r,null,t)}}}})],x.prototype,"filter",void 0),(0,i._)([(0,s.Cb)({json:{write:!0,origins:{"web-map":_,"portal-item":_}}})],x.prototype,"includedEffect",void 0),(0,i._)([(0,s.Cb)({json:{write:!0,origins:{"web-map":F,"portal-item":F}}})],x.prototype,"excludedEffect",void 0),(0,i._)([(0,s.Cb)({type:Boolean,json:{write:!0,name:"showExcludedLabels",origins:{"web-map":T,"portal-item":T}}})],x.prototype,"excludedLabelsVisible",void 0),x=v=(0,i._)([(0,o.j)("esri.layers.support.FeatureEffect")],x);const I=x,C={write:{allowNull:!0}},S=e=>{let t=class extends e{constructor(){super(...arguments),this.featureEffect=null}};return(0,i._)([(0,s.Cb)({type:I,json:{origins:{"web-map":C,"portal-item":C}}})],t.prototype,"featureEffect",void 0),t=(0,i._)([(0,o.j)("esri.layers.mixins.FeatureEffectLayer")],t),t}},68825:(e,t,r)=>{r.d(t,{c:()=>y});var n,i=r(43697),s=r(78286),o=r(5600),l=(r(75215),r(67676),r(80442),r(52011)),a=r(35454),u=r(96674);const p=new a.X({asc:"ascending",desc:"descending"});let d=n=class extends u.wq{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._)([(0,o.Cb)({type:String,json:{write:!0}})],d.prototype,"field",void 0),(0,i._)([(0,o.Cb)({type:String,json:{write:!0}})],d.prototype,"valueExpression",void 0),(0,i._)([(0,o.Cb)({type:p.apiValues,json:{read:p.read,write:p.write}})],d.prototype,"order",void 0),d=n=(0,i._)([(0,l.j)("esri.layers.support.OrderByInfo")],d);const c=d;function h(e,t,r){if(!e)return null;const n=e.find((e=>!!e.field));if(!n)return null;const i=new c;return i.read(n,r),[i]}function f(e,t,r,n){const i=e.find((e=>!!e.field));i&&(0,s.RB)(r,[i.toJSON()],t)}const y=e=>{let t=class extends e{constructor(){super(...arguments),this.orderBy=null}};return(0,i._)([(0,o.Cb)({type:[c],json:{origins:{"web-scene":{write:!1,read:!1}},read:{source:"layerDefinition.orderBy",reader:h},write:{target:"layerDefinition.orderBy",writer:f}}})],t.prototype,"orderBy",void 0),t=(0,i._)([(0,l.j)("esri.layers.mixins.OrderedLayer")],t),t}},34760:(e,t,r)=>{r.d(t,{Q:()=>b});var n=r(43697),i=r(92604),s=r(95330),o=r(5600),l=r(90578),a=(r(67676),r(80442),r(52011)),u=r(82960),p=r(46791),d=(r(66643),r(20102),r(26258),r(87538));const c=new p.Z,h=new WeakMap;function f(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&c.push(new WeakRef(e))}function y(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:y(t,e%t):0}let m=0,g=0;function w(){const e=Date.now();let t=!1;for(const r of c){const n=r.deref();n?n.refreshInterval&&e-(h.get(n)??0)+5>=6e4*n.refreshInterval&&(h.set(n,e),n.refresh(e)):t=!0}if(t)for(let e=c.length-1;e>=0;e--)c.at(e).deref()||c.removeAt(e)}(0,d.EH)((()=>{const e=Date.now();let t=0;for(const r of c){const n=r.deref();n&&(t=y(Math.round(6e4*n.refreshInterval),t),n.refreshInterval?h.get(n)||h.set(n,e):h.delete(n))}if(t!==g){if(g=t,clearInterval(m),0===g)return void(m=0);m=setInterval(w,g)}}));const b=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,s.Ds)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||f(this)}),(()=>{}))}destroy(){!function(e){const t=c.find((t=>t.deref()===e));t&&c.remove(t)}(this)}castRefreshInterval(e){return e>=.1?e:e<=0?0:.1}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,s.R8)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{i.Z.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){const e=this;return{set refreshInterval(t){e._set("refreshInterval",t)}}}};return(0,n._)([(0,o.Cb)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:u.C}}}}})],t.prototype,"refreshInterval",void 0),(0,n._)([(0,l.p)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,n._)([(0,o.Cb)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,n._)([(0,a.j)("esri.layers.mixins.RefreshableLayer")],t),t}},28294:(e,t,r)=>{r.d(t,{n:()=>c});var n=r(43697),i=r(92835),s=r(84552),o=r(5600),l=(r(75215),r(67676),r(80442),r(71715)),a=r(52011),u=r(69165),p=r(76259),d=r(78981);const c=e=>{let t=class extends e{constructor(){super(...arguments),this.timeExtent=null,this.timeOffset=null,this.useViewTime=!0}readOffset(e,t){const r=t.timeInfo.exportOptions;if(!r)return null;const n=r.timeOffset,i=d.v.fromJSON(r.timeOffsetUnits);return n&&i?new s.Z({value:n,unit:i}):null}set timeInfo(e){(0,u.UF)(e,this.fieldsIndex),this._set("timeInfo",e)}};return(0,n._)([(0,o.Cb)({type:i.Z,json:{write:!1}})],t.prototype,"timeExtent",void 0),(0,n._)([(0,o.Cb)({type:s.Z})],t.prototype,"timeOffset",void 0),(0,n._)([(0,l.r)("service","timeOffset",["timeInfo.exportOptions"])],t.prototype,"readOffset",null),(0,n._)([(0,o.Cb)({value:null,type:p.Z,json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],t.prototype,"timeInfo",null),(0,n._)([(0,o.Cb)({type:Boolean,json:{read:{source:"timeAnimation"},write:{target:"timeAnimation"},origins:{"web-scene":{read:!1,write:!1}}}})],t.prototype,"useViewTime",void 0),t=(0,n._)([(0,a.j)("esri.layers.mixins.TemporalLayer")],t),t}},70082:(e,t,r)=>{r.d(t,{Z:()=>d});var n=r(43697),i=r(2368),s=r(35454),o=r(96674),l=r(5600),a=(r(75215),r(67676),r(80442),r(52011));const u=new s.X({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.J)(o.wq)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,n._)([(0,l.Cb)({json:{write:!0}})],p.prototype,"name",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],p.prototype,"description",void 0),(0,n._)([(0,l.Cb)({json:{read:u.read,write:u.write}})],p.prototype,"drawingTool",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],p.prototype,"prototype",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],p.prototype,"thumbnail",void 0),p=(0,n._)([(0,a.j)("esri.layers.support.FeatureTemplate")],p);const d=p},16451:(e,t,r)=>{r.d(t,{Z:()=>h});var n=r(43697),i=r(2368),s=r(96674),o=r(5600),l=(r(75215),r(67676),r(80442),r(71715)),a=r(52011),u=r(30556),p=r(72729),d=r(70082);let c=class extends((0,i.J)(s.wq)){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.im)(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._)([(0,o.Cb)({json:{write:!0}})],c.prototype,"id",void 0),(0,n._)([(0,o.Cb)({json:{write:!0}})],c.prototype,"name",void 0),(0,n._)([(0,o.Cb)({json:{write:!0}})],c.prototype,"domains",void 0),(0,n._)([(0,l.r)("domains")],c.prototype,"readDomains",null),(0,n._)([(0,u.c)("domains")],c.prototype,"writeDomains",null),(0,n._)([(0,o.Cb)({type:[d.Z],json:{write:!0}})],c.prototype,"templates",void 0),c=(0,n._)([(0,a.j)("esri.layers.support.FeatureType")],c);const h=c},99514:(e,t,r)=>{r.d(t,{Z:()=>a});var n=r(20102),i=r(96674),s=r(92604),o=r(69165),l=r(25031);class a{static fromJSON(e){return new a(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new a(e.fields??[],c(e))}static fromLayerJSON(e){return new a(e.fields??[],c(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const r=[];for(const e of this.fields){const t=e?.name,n=p(t);if(t&&n){const i=u(t);this._fieldsMap.set(t,e),this._fieldsMap.set(i,e),this._normalizedFieldsMap.set(n,e),r.push(`${i}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,o.y2)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,o.H7)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,o.Dl)(e)||(0,o.Se)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}r.sort(),this.uid=r.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,o.Dl)(e)||(0,o.Se)(e)||e.nullable||void 0!==(0,o.os)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(u(e))??this._normalizedFieldsMap.get(p(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(s.Z.getLogger("esri.layers.support.FieldsIndex").error(new n.Z("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),l.pt):d.has(t.type)?l._4:null:null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,o.sX)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,i.AK)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function u(e){return e.trim().toLowerCase()}function p(e){return(0,o.q6)(e)?.toLowerCase()??""}const d=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function c(e){const t=new Map;if(!e.fields)return t;const r=!0===e.datesInUnknownTimezone,{timeInfo:n,editFieldsInfo:i}=e,s=(n?"startField"in n?n.startField:n.startTimeField:"")??"",o=(n?"endField"in n?n.endField:n.endTimeField:"")??"",a=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,l.Jv)(e.dateFieldsTimeReference):null,p=i?function(e){return"timeZone"in e}(i)?i.timeZone??a:i.dateFieldsTimeReference?(0,l.Jv)(i.dateFieldsTimeReference):a??l.pt:null,c=n?function(e){return"timeZone"in e}(n)?n.timeZone??a:n.timeReference?(0,l.Jv)(n.timeReference):a:null,h=new Map([[u(i?.creationDateField??""),p],[u(i?.editDateField??""),p],[u(s),c],[u(o),c]]);for(const{name:n,type:i}of e.fields)if(d.has(i))t.set(n,l._4);else if("date"!==i&&"esriFieldTypeDate"!==i)t.set(n,null);else if(r)t.set(n,l._4);else{const e=h.get(u(n??""))??a;t.set(n,e)}return t}},76259:(e,t,r)=>{r.d(t,{Z:()=>y});var n=r(43697),i=r(92835),s=r(84552),o=r(2368),l=r(96674),a=r(5600),u=(r(75215),r(67676),r(80442),r(71715)),p=r(52011),d=r(30556),c=r(25031);function h(e,t){return s.Z.fromJSON({value:e,unit:t})}let f=class extends((0,o.J)(l.wq)){constructor(e){super(e),this.cumulative=!1,this.endField=null,this.fullTimeExtent=null,this.hasLiveData=!1,this.interval=null,this.startField=null,this.timeZone=null,this.trackIdField=null,this.useTime=!0}readFullTimeExtent(e,t){if(!t.timeExtent||!Array.isArray(t.timeExtent)||2!==t.timeExtent.length)return null;const r=new Date(t.timeExtent[0]),n=new Date(t.timeExtent[1]);return new i.Z({start:r,end:n})}writeFullTimeExtent(e,t){null!=e?.start&&null!=e.end?t.timeExtent=[e.start.getTime(),e.end.getTime()]:t.timeExtent=null}readInterval(e,t){return t.timeInterval&&t.timeIntervalUnits?h(t.timeInterval,t.timeIntervalUnits):t.defaultTimeInterval&&t.defaultTimeIntervalUnits?h(t.defaultTimeInterval,t.defaultTimeIntervalUnits):null}writeInterval(e,t){t.timeInterval=e?.toJSON().value??null,t.timeIntervalUnits=e?.toJSON().unit??null}};(0,n._)([(0,a.Cb)({type:Boolean,json:{name:"exportOptions.timeDataCumulative",write:!0}})],f.prototype,"cumulative",void 0),(0,n._)([(0,a.Cb)({type:String,json:{name:"endTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"endField",void 0),(0,n._)([(0,a.Cb)({type:i.Z,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"fullTimeExtent",void 0),(0,n._)([(0,u.r)("fullTimeExtent",["timeExtent"])],f.prototype,"readFullTimeExtent",null),(0,n._)([(0,d.c)("fullTimeExtent")],f.prototype,"writeFullTimeExtent",null),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],f.prototype,"hasLiveData",void 0),(0,n._)([(0,a.Cb)({type:s.Z,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"interval",void 0),(0,n._)([(0,u.r)("interval",["timeInterval","timeIntervalUnits","defaultTimeInterval","defaultTimeIntervalUnits"])],f.prototype,"readInterval",null),(0,n._)([(0,d.c)("interval")],f.prototype,"writeInterval",null),(0,n._)([(0,a.Cb)({type:String,json:{name:"startTimeField",write:{enabled:!0,allowNull:!0}}})],f.prototype,"startField",void 0),(0,n._)([(0,a.Cb)((0,c.mi)("timeReference",!0))],f.prototype,"timeZone",void 0),(0,n._)([(0,a.Cb)({type:String,json:{write:{enabled:!0,allowNull:!0}}})],f.prototype,"trackIdField",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{name:"exportOptions.useTime",write:!0}})],f.prototype,"useTime",void 0),f=(0,n._)([(0,p.j)("esri.layers.support.TimeInfo")],f);const y=f},86719:(e,t,r)=>{r.d(t,{v:()=>n});const n=new(r(35454).X)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},78981:(e,t,r)=>{r.d(t,{v:()=>n});const n=(0,r(35454).w)()({esriTimeUnitsMilliseconds:"milliseconds",esriTimeUnitsSeconds:"seconds",esriTimeUnitsMinutes:"minutes",esriTimeUnitsHours:"hours",esriTimeUnitsDays:"days",esriTimeUnitsWeeks:"weeks",esriTimeUnitsMonths:"months",esriTimeUnitsYears:"years",esriTimeUnitsDecades:"decades",esriTimeUnitsCenturies:"centuries",esriTimeUnitsUnknown:void 0})},74889:(e,t,r)=>{r.d(t,{Z:()=>b});var n,i=r(43697),s=r(66577),o=r(38171),l=r(35454),a=r(96674),u=r(22974),p=r(5600),d=(r(75215),r(71715)),c=r(52011),h=r(30556),f=r(82971),y=r(33955),m=r(1231);const g=new l.X({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let w=n=class extends a.wq{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){const r=f.Z.fromJSON(t.spatialReference),n=[];for(let t=0;t<e.length;t++){const i=e[t],s=o.Z.fromJSON(i),l=i.geometry?.spatialReference;null==s.geometry||l||(s.geometry.spatialReference=r);const a=i.aggregateGeometries,u=s.aggregateGeometries;if(a&&null!=u)for(const e in u){const t=u[e],n=a[e],i=n?.spatialReference;null==t||i||(t.spatialReference=r)}n.push(s)}return n}writeGeometryType(e,t,r,n){if(e)return void g.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void g.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,y.im)(e);return n&&!r&&t.spatialReference&&(n.spatialReference=f.Z.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,u.d9)({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}_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,y.oU)(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,y.oU)(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,y.oU)(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._)([(0,p.Cb)({type:String,json:{write:!0}})],w.prototype,"displayFieldName",void 0),(0,i._)([(0,p.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"exceededTransferLimit",void 0),(0,i._)([(0,p.Cb)({type:[o.Z],json:{write:!0}})],w.prototype,"features",void 0),(0,i._)([(0,d.r)("features")],w.prototype,"readFeatures",null),(0,i._)([(0,p.Cb)({type:[m.Z],json:{write:!0}})],w.prototype,"fields",void 0),(0,i._)([(0,p.Cb)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],w.prototype,"geometryType",void 0),(0,i._)([(0,h.c)("geometryType")],w.prototype,"writeGeometryType",null),(0,i._)([(0,p.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasM",void 0),(0,i._)([(0,p.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],w.prototype,"hasZ",void 0),(0,i._)([(0,p.Cb)({types:s.qM,json:{write:!0}})],w.prototype,"queryGeometry",void 0),(0,i._)([(0,d.r)("queryGeometry")],w.prototype,"readQueryGeometry",null),(0,i._)([(0,p.Cb)({type:f.Z,json:{write:!0}})],w.prototype,"spatialReference",void 0),(0,i._)([(0,h.c)("spatialReference")],w.prototype,"writeSpatialReference",null),(0,i._)([(0,p.Cb)({json:{write:!0}})],w.prototype,"transform",void 0),w=n=(0,i._)([(0,c.j)("esri.rest.support.FeatureSet")],w),w.prototype.toJSON.isDefaultToJSON=!0;const b=w}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6618,5732,447],{5732:(e,t,r)=>{r.d(t,{c:()=>n,g:()=>i});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function i(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}},22862:(e,t,r)=>{r.d(t,{Hg:()=>f,V7:()=>y,uD:()=>d});var n=r(92036),i=r(46791),o=r(1153);const s=new Set(["esri.Color","esri.portal.Portal","esri.symbols.support.Symbol3DAnchorPosition2D","esri.symbols.support.Symbol3DAnchorPosition3D"]);function l(e){return e instanceof n.Z}function a(e){return e instanceof i.Z?Object.keys(e.items):l(e)?(0,o.vw)(e).keys():e?Object.keys(e):[]}function p(e,t){return e instanceof i.Z?e.items[t]:e[t]}function u(e){return e?e.declaredClass:null}function c(e,t){const r=e.diff;if(r&&"function"==typeof r)return r(e,t);const n=a(e),i=a(t);if(0===n.length&&0===i.length)return;if(!n.length||!i.length||function(e,t){return!(!Array.isArray(e)||!Array.isArray(t))&&e.length!==t.length}(e,t))return{type:"complete",oldValue:e,newValue:t};const o=i.filter((e=>!n.includes(e))),d=n.filter((e=>!i.includes(e))),y=n.filter((r=>i.includes(r)&&p(e,r)!==p(t,r))).concat(o,d).sort(),f=u(e);if(f&&s.has(f)&&y.length)return{type:"complete",oldValue:e,newValue:t};let h;const m=l(e)&&l(t);for(const n of y){const i=p(e,n),o=p(t,n);let s;if((m||"function"!=typeof i&&"function"!=typeof o)&&i!==o&&(null!=i||null!=o)){if(r&&r[n]&&"function"==typeof r[n])s=r[n]?.(i,o);else if(i instanceof Date&&o instanceof Date){if(i.getTime()===o.getTime())continue;s={type:"complete",oldValue:i,newValue:o}}else s="object"==typeof i&&"object"==typeof o&&u(i)===u(o)?c(i,o):{type:"complete",oldValue:i,newValue:o};null!=s&&(null!=h?h.diff[n]=s:h={type:"partial",diff:{[n]:s}})}}return h}function d(e,t){if(null==e)return!1;const r=t.split(".");let n=e;for(const e of r){if("complete"===n.type)return!0;if("partial"!==n.type)return!1;{const t=n.diff[e];if(!t)return!1;n=t}}return!0}function y(e,t){for(const r of t)if(d(e,r))return!0;return!1}function f(e,t){if("function"!=typeof e&&"function"!=typeof t&&(null!=e||null!=t))return null==e||null==t||"object"==typeof e&&"object"==typeof t&&u(e)!==u(t)?{type:"complete",oldValue:e,newValue:t}:c(e,t)}},60437:(e,t,r)=>{r.d(t,{G_:()=>b,HH:()=>s,JR:()=>f,TC:()=>l,Tn:()=>c,Ue:()=>i,al:()=>o,bZ:()=>h,cS:()=>y,dp:()=>p,fS:()=>g,is:()=>m,op:()=>u,pp:()=>a,t8:()=>d});var n=r(6570);function i(e=w){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function o(e,t,r,n,o,s,l=i()){return l[0]=e,l[1]=t,l[2]=r,l[3]=n,l[4]=o,l[5]=s,l}function s(e,t){const r=isFinite(e[2])||isFinite(e[5]);return new n.Z(r?{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}:{xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function l(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[3]),e[4]=Math.max(e[4],t[4]),e[5]=Math.max(e[5],t[5])}function a(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.min(e[2],t[2]),e[3]=Math.max(e[3],t[0]),e[4]=Math.max(e[4],t[1]),e[5]=Math.max(e[5],t[2])}function p(e,t=[0,0,0]){return t[0]=function(e){return e[0]>=e[3]?0:e[3]-e[0]}(e),t[1]=function(e){return e[1]>=e[4]?0:e[4]-e[1]}(e),t[2]=function(e){return e[2]>=e[5]?0:e[5]-e[2]}(e),t}function u(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function c(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function d(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function y(e){return e?d(e,b):i(b)}function f(e,t){return e[0]=t[0],e[1]=t[1],e[2]=Number.NEGATIVE_INFINITY,e[3]=t[2],e[4]=t[3],e[5]=Number.POSITIVE_INFINITY,e}function h(e,t,r,n,i){return e[0]=t,e[1]=r,e[2]=Number.NEGATIVE_INFINITY,e[3]=n,e[4]=i,e[5]=Number.POSITIVE_INFINITY,e}function m(e){return 6===e.length}function g(e,t,r){if(null==e||null==t)return e===t;if(!m(e)||!m(t))return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}r(24470);const b=[1/0,1/0,1/0,-1/0,-1/0,-1/0],w=[0,0,0,0,0,0];i()},16306:(e,t,r)=>{r.d(t,{aX:()=>_});var n=r(68773),i=r(20102),o=r(92604),s=r(38913),l=r(58901),a=r(73913),p=r(8744),u=r(40488),c=(r(66577),r(3172)),d=r(33955),y=r(11282),f=r(17452);async function h(e,t,r){const n="string"==typeof e?(0,f.mN)(e):e,i=t[0].spatialReference,o=(0,d.Ji)(t[0]),s={...r,query:{...n.query,f:"json",sr:(0,p.B9)(i),geometries:JSON.stringify((a=t,{geometryType:(0,d.Ji)(a[0]),geometries:a.map((e=>e.toJSON()))}))}},{data:l}=await(0,c.Z)(n.path+"/simplify",s);var a;return function(e,t,r){const n=(0,d.q9)(t);return e.map((e=>{const t=n.fromJSON(e);return t.spatialReference=r,t}))}(l.geometries,o,i)}const m=o.Z.getLogger("esri.geometry.support.normalizeUtils");function g(e){return"polygon"===e[0].type}function b(e){return"polyline"===e[0].type}function w(e,t,r){if(t){const t=function(e,t){if(!(e instanceof l.Z||e instanceof s.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw m.error(e),new i.Z(e)}const r=(0,a.x3)(e),n=[];for(const e of r){const r=[];n.push(r),r.push([e[0][0],e[0][1]]);for(let n=0;n<e.length-1;n++){const i=e[n][0],o=e[n][1],s=e[n+1][0],l=e[n+1][1],a=Math.sqrt((s-i)*(s-i)+(l-o)*(l-o)),p=(l-o)/a,u=(s-i)/a,c=a/t;if(c>1){for(let e=1;e<=c-1;e++){const n=e*t,s=u*n+i,l=p*n+o;r.push([s,l])}const e=(a+Math.floor(c-1)*t)/2,n=u*e+i,s=p*e+o;r.push([n,s])}r.push([s,l])}}return function(e){return"polygon"===e.type}(e)?new s.Z({rings:n,spatialReference:e.spatialReference}):new l.Z({paths:n,spatialReference:e.spatialReference})}(e,1e6);e=(0,u.Sx)(t,!0)}return r&&(e=(0,a.Sy)(e,r)),e}function S(e,t,r){if(Array.isArray(e)){const n=e[0];if(n>t){const r=(0,a.XZ)(n,t);e[0]=n+r*(-2*t)}else if(n<r){const t=(0,a.XZ)(n,r);e[0]=n+t*(-2*r)}}else{const n=e.x;if(n>t){const r=(0,a.XZ)(n,t);e=e.clone().offset(r*(-2*t),0)}else if(n<r){const t=(0,a.XZ)(n,r);e=e.clone().offset(t*(-2*r),0)}}return e}function v(e,t){let r=-1;for(let n=0;n<t.cutIndexes.length;n++){const i=t.cutIndexes[n],o=t.geometries[n],s=(0,a.x3)(o);for(let e=0;e<s.length;e++){const t=s[e];t.some((r=>{if(r[0]<180)return!0;{let r=0;for(let e=0;e<t.length;e++){const n=t[e][0];r=n>r?n:r}r=Number(r.toFixed(9));const n=-360*(0,a.XZ)(r,180);for(let r=0;r<t.length;r++){const t=o.getPoint(e,r);o.setPoint(e,r,t.clone().offset(n,0))}return!0}}))}if(i===r){if(g(e))for(const t of(0,a.x3)(o))e[i]=e[i].addRing(t);else if(b(e))for(const t of(0,a.x3)(o))e[i]=e[i].addPath(t)}else r=i,e[i]=o}return e}async function _(e,t,r){if(!Array.isArray(e))return _([e],t);t&&"string"!=typeof t&&m.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const i="string"==typeof t?t:t?.url??n.default.geometryServiceUrl;let o,f,g,b,C,T,x,F,O=0;const N=[],R=[];for(const t of e)if(null!=t)if(o||(o=t.spatialReference,f=(0,p.C5)(o),g=o.isWebMercator,T=g?102100:4326,b=a.UZ[T].maxX,C=a.UZ[T].minX,x=a.UZ[T].plus180Line,F=a.UZ[T].minus180Line),f)if("mesh"===t.type)R.push(t);else if("point"===t.type)R.push(S(t.clone(),b,C));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>S(e,b,C))),R.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,f);R.push(e.rings?new s.Z(e):e)}else if(t.extent){const e=t.extent,r=(0,a.XZ)(e.xmin,C)*(2*b);let n=0===r?t.clone():(0,a.Sy)(t.clone(),r);e.offset(r,0),e.intersects(x)&&e.xmax!==b?(O=e.xmax>O?e.xmax:O,n=w(n,g),N.push(n),R.push("cut")):e.intersects(F)&&e.xmin!==C?(O=e.xmax*(2*b)>O?e.xmax*(2*b):O,n=w(n,g,360),N.push(n),R.push("cut")):R.push(n)}else R.push(t.clone());else R.push(t);else R.push(t);let Z=(0,a.XZ)(O,b),M=-90;const j=Z,I=new l.Z;for(;Z>0;){const e=360*Z-180;I.addPath([[e,M],[e,-1*M]]),M*=-1,Z--}if(N.length>0&&j>0){const t=v(N,await async function(e,t,r,n){const i=(0,y.en)(e),o=t[0].spatialReference,s={...n,responseType:"json",query:{...i.query,f:"json",sr:(0,p.B9)(o),target:JSON.stringify({geometryType:(0,d.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(r)}},l=await(0,c.Z)(i.path+"/cut",s),{cutIndexes:a,geometries:u=[]}=l.data;return{cutIndexes:a,geometries:u.map((e=>{const t=(0,d.im)(e);return t.spatialReference=o,t}))}}(i,N,I,r)),n=[],o=[];for(let r=0;r<R.length;r++){const i=R[r];if("cut"!==i)o.push(i);else{const i=t.shift(),s=e[r];null!=s&&"polygon"===s.type&&s.rings&&s.rings.length>1&&i.rings.length>=s.rings.length?(n.push(i),o.push("simplify")):o.push(g?(0,u.$)(i):i)}}if(!n.length)return o;const s=await h(i,n,r),l=[];for(let e=0;e<o.length;e++){const t=o[e];"simplify"!==t?l.push(t):l.push(g?(0,u.$)(s.shift()):s.shift())}return l}const A=[];for(let e=0;e<R.length;e++){const t=R[e];if("cut"!==t)A.push(t);else{const e=N.shift();A.push(!0===g?(0,u.$)(e):e)}}return A}},73913:(e,t,r)=>{r.d(t,{Sy:()=>a,UZ:()=>s,XZ:()=>l,x3:()=>p});var n=r(58901),i=r(82971),o=r(33955);const s={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new n.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:i.Z.WebMercator}),minus180Line:new n.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:i.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new n.Z({paths:[[[180,-180],[180,180]]],spatialReference:i.Z.WGS84}),minus180Line:new n.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:i.Z.WGS84})}};function l(e,t){return Math.ceil((e-t)/(2*t))}function a(e,t){const r=p(e);for(const e of r)for(const r of e)r[0]+=t;return e}function p(e){return(0,o.oU)(e)?e.rings:e.paths}},62128:(e,t,r)=>{r.r(t),r.d(t,{default:()=>K});var n=r(43697),i=(r(66577),r(38171)),o=(r(9790),r(46791)),s=r(20102),l=r(22974),a=r(16453),p=r(78286),u=r(20941),c=r(5600),d=r(75215),y=r(71715),f=r(52011),h=r(30556),m=r(73615),g=r(24470),b=r(16306),w=r(8744),S=r(19238),v=(r(67676),r(80442),r(70921));r(92604);let _=class extends o.Z{constructor(e){super(e),this.addHandles([this.on("before-add",(e=>{null==e.item&&e.preventDefault()})),this.on("after-add",(e=>this._own(e.item))),this.on("after-remove",(e=>this._release(e.item)))])}get owner(){return this._get("owner")}set owner(e){e!==this._get("owner")&&(this._releaseAll(),this._set("owner",e),this._ownAll())}_ownAll(){for(const e of this.items)this._own(e)}_releaseAll(){for(const e of this.items)this._release(e)}_createNewInstance(e){return this.itemType?new(o.Z.ofType(this.itemType.Type))(e):new o.Z(e)}};(0,n._)([(0,c.Cb)()],_.prototype,"owner",null),_=(0,n._)([(0,f.j)("esri.core.support.OwningCollection")],_);var C=r(87085),T=r(71612),x=r(72965),F=r(52421);let O=class extends _{_own(e){e.layer&&"remove"in e.layer&&e.layer!==this.owner&&e.layer.remove(e),e.layer=this.owner}_release(e){e.layer===this.owner&&(e.layer=null)}};(0,n._)([(0,F.c)({Type:i.Z,ensureType:(0,d.se)(i.Z)})],O.prototype,"itemType",void 0),O=(0,n._)([(0,f.j)("esri.support.GraphicsCollection")],O);var N=r(86787);let R=class extends((0,T.h)((0,x.M)(C.Z))){constructor(e){super(e),this.elevationInfo=null,this.graphics=new O,this.screenSizePerspectiveEnabled=!0,this.type="graphics",this.internal=!1}destroy(){this.removeAll(),this.graphics.destroy()}add(e){return this.graphics.add(e),this}addMany(e){return this.graphics.addMany(e),this}removeAll(){return this.graphics.removeAll(),this}remove(e){this.graphics.remove(e)}removeMany(e){this.graphics.removeMany(e)}on(e,t){return super.on(e,t)}graphicChanged(e){this.emit("graphic-update",e)}};var Z,M;(0,n._)([(0,c.Cb)({type:N.Z})],R.prototype,"elevationInfo",void 0),(0,n._)([(0,c.Cb)((Z=O,M="graphics",{type:Z,cast:v.R,set(e){const t=(0,v.Z)(e,this._get(M),Z);t.owner=this,this._set(M,t)}}))],R.prototype,"graphics",void 0),(0,n._)([(0,c.Cb)({type:["show","hide"]})],R.prototype,"listMode",void 0),(0,n._)([(0,c.Cb)()],R.prototype,"screenSizePerspectiveEnabled",void 0),(0,n._)([(0,c.Cb)({readOnly:!0})],R.prototype,"type",void 0),(0,n._)([(0,c.Cb)({constructOnly:!0})],R.prototype,"internal",void 0),R=(0,n._)([(0,f.j)("esri.layers.GraphicsLayer")],R);const j=R;var I=r(92908),A=r(38009),L=r(16859),D=r(1231),J=r(20256),E=r(4095),P=r(77987),z=r(78724),V=r(82971),q=r(6570);function G(e){return"markup"===e.featureCollectionType||e.layers.some((e=>null!=e.layerDefinition.visibilityField||!Q(e)))}function Q({layerDefinition:e,featureSet:t}){const r=e.geometryType??t.geometryType;return X.find((t=>r===t.geometryTypeJSON&&e.drawingInfo?.renderer?.symbol?.type===t.identifyingSymbol.type))}function B(){return new q.Z({xmin:-180,ymin:-90,xmax:180,ymax:90})}const k=new D.Z({name:"OBJECTID",alias:"OBJECTID",type:"oid",nullable:!1,editable:!1}),U=new D.Z({name:"title",alias:"Title",type:"string",nullable:!0,editable:!0,length:255});let H=class extends j{constructor(e){super(e),this.visibilityMode="inherited"}initialize(){for(const e of this.graphics)e.sourceLayer=this.layer;this.graphics.on("after-add",(e=>{e.item.sourceLayer=this.layer})),this.graphics.on("after-remove",(e=>{e.item.sourceLayer=null}))}get fullExtent(){const e=this.layer?.spatialReference,t=this.fullBounds;return e?null==t?(0,m.projectOrLoad)(B(),e).geometry:(0,g.HH)(t,e):null}get fullBounds(){const e=this.layer?.spatialReference;if(!e)return null;const t=(0,g.cS)();return this.graphics.forEach((r=>{const n=null!=r.geometry?(0,m.projectOrLoad)(r.geometry,e).geometry:null;null!=n&&(0,g.jn)(t,"point"===n.type?n:n.extent,t)})),(0,g.fS)(t,g.G_)?null:t}get sublayers(){return this.graphics}};(0,n._)([(0,c.Cb)({readOnly:!0})],H.prototype,"fullExtent",null),(0,n._)([(0,c.Cb)({readOnly:!0})],H.prototype,"fullBounds",null),(0,n._)([(0,c.Cb)({readOnly:!0})],H.prototype,"sublayers",null),(0,n._)([(0,c.Cb)()],H.prototype,"layer",void 0),(0,n._)([(0,c.Cb)()],H.prototype,"layerId",void 0),(0,n._)([(0,c.Cb)({readOnly:!0})],H.prototype,"visibilityMode",void 0),H=(0,n._)([(0,f.j)("esri.layers.MapNotesLayer.MapNotesSublayer")],H);const X=[{geometryType:"polygon",geometryTypeJSON:"esriGeometryPolygon",id:"polygonLayer",layerId:0,title:"Polygons",identifyingSymbol:(new J.Z).toJSON()},{geometryType:"polyline",geometryTypeJSON:"esriGeometryPolyline",id:"polylineLayer",layerId:1,title:"Polylines",identifyingSymbol:(new E.Z).toJSON()},{geometryType:"multipoint",geometryTypeJSON:"esriGeometryMultipoint",id:"multipointLayer",layerId:2,title:"Multipoints",identifyingSymbol:(new P.Z).toJSON()},{geometryType:"point",geometryTypeJSON:"esriGeometryPoint",id:"pointLayer",layerId:3,title:"Points",identifyingSymbol:(new P.Z).toJSON()},{geometryType:"point",geometryTypeJSON:"esriGeometryPoint",id:"textLayer",layerId:4,title:"Text",identifyingSymbol:(new z.Z).toJSON()}];let W=class extends((0,T.h)((0,x.M)((0,A.q)((0,L.I)((0,a.R)(C.Z)))))){constructor(e){super(e),this.capabilities={operations:{supportsMapNotesEditing:!0}},this.featureCollections=null,this.featureCollectionJSON=null,this.featureCollectionType="notes",this.legendEnabled=!1,this.listMode="hide-children",this.minScale=0,this.maxScale=0,this.spatialReference=V.Z.WGS84,this.sublayers=new o.Z(X.map((e=>new H({id:e.id,layerId:e.layerId,title:e.title,layer:this})))),this.title="Map Notes",this.type="map-notes",this.visibilityMode="inherited"}readCapabilities(e,t,r){return{operations:{supportsMapNotesEditing:!G(t)&&"portal-item"!==r?.origin}}}readFeatureCollections(e,t,r){if(!G(t))return null;const n=t.layers.map((e=>{const t=new S.default;return t.read(e,r),t}));return new o.Z({items:n})}readLegacyfeatureCollectionJSON(e,t){return G(t)?(0,l.d9)(t.featureCollection):null}get fullExtent(){const e=this.spatialReference,t=(0,g.cS)();return null!=this.sublayers?this.sublayers.forEach((({fullBounds:e})=>null!=e?(0,g.jn)(t,e,t):t),t):this.featureCollectionJSON?.layers.some((e=>e.layerDefinition.extent))&&this.featureCollectionJSON.layers.forEach((r=>{const n=(0,m.projectOrLoad)(r.layerDefinition.extent,e).geometry;null!=n&&(0,g.jn)(t,n,t)})),(0,g.fS)(t,g.G_)?(0,m.projectOrLoad)(B(),e).geometry:(0,g.HH)(t,e)}readMinScale(e,t){for(const e of t.layers)if(null!=e.layerDefinition.minScale)return e.layerDefinition.minScale;return 0}readMaxScale(e,t){for(const e of t.layers)if(null!=e.layerDefinition.maxScale)return e.layerDefinition.maxScale;return 0}get multipointLayer(){return this._findSublayer("multipointLayer")}get pointLayer(){return this._findSublayer("pointLayer")}get polygonLayer(){return this._findSublayer("polygonLayer")}get polylineLayer(){return this._findSublayer("polylineLayer")}readSpatialReference(e,t){return t.layers.length?V.Z.fromJSON(t.layers[0].layerDefinition.spatialReference):V.Z.WGS84}readSublayers(e,t,r){if(G(t))return null;const n=[];let s=t.layers.reduce(((e,t)=>Math.max(e,t.layerDefinition.id??-1)),-1)+1;for(const e of t.layers){const{layerDefinition:t,featureSet:r}=e,o=t.id??s++,l=Q(e);if(null!=l){const e=new H({id:l.id,title:t.name,layerId:o,layer:this,graphics:r.features.map((({geometry:e,symbol:t,attributes:r,popupInfo:n})=>i.Z.fromJSON({attributes:r,geometry:e,symbol:t,popupTemplate:n})))});n.push(e)}}return new o.Z(n)}writeSublayers(e,t,r,n){const{minScale:i,maxScale:o}=this;if(null==e)return;const l=e.some((e=>e.graphics.length>0));if(!this.capabilities.operations.supportsMapNotesEditing)return void(l&&n?.messages?.push(new s.Z("map-notes-layer:editing-not-supported","New map notes cannot be added to this layer")));const a=[];let u=this.spatialReference.toJSON();e:for(const t of e)for(const e of t.graphics)if(null!=e.geometry){u=e.geometry.spatialReference.toJSON();break e}for(const t of X){const r=e.find((e=>t.id===e.id));this._writeMapNoteSublayer(a,r,t,i,o,u,n)}(0,p.RB)("featureCollection.layers",a,t)}get textLayer(){return this._findSublayer("textLayer")}load(e){return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Feature Collection"]},e)),Promise.resolve(this)}read(e,t){"featureCollection"in e&&(e=(0,l.d9)(e),Object.assign(e,e.featureCollection)),super.read(e,t)}async beforeSave(){if(null==this.sublayers)return;let e=null;const t=[];for(const r of this.sublayers)for(const n of r.graphics)if(null!=n.geometry){const r=n.geometry;e?(0,w.fS)(r.spatialReference,e)||((0,m.canProjectWithoutEngine)(r.spatialReference,e)||(0,m.isLoaded)()||await(0,m.load)(),n.geometry=(0,m.project)(r,e)):e=r.spatialReference,t.push(n)}const r=await(0,b.aX)(t.map((e=>e.geometry)));t.forEach(((e,t)=>e.geometry=r[t]))}_findSublayer(e){return null==this.sublayers?null:this.sublayers?.find((t=>t.id===e))??null}_writeMapNoteSublayer(e,t,r,n,i,o,s){const a=[];if(null!=t){for(const e of t.graphics)this._writeMapNote(a,e,r.geometryType,s);this._normalizeObjectIds(a,k),e.push({layerDefinition:{name:t.title,drawingInfo:{renderer:{type:"simple",symbol:(0,l.d9)(r.identifyingSymbol)}},id:t.layerId,geometryType:r.geometryTypeJSON,minScale:n,maxScale:i,objectIdField:"OBJECTID",fields:[k.toJSON(),U.toJSON()],spatialReference:o},featureSet:{features:a,geometryType:r.geometryTypeJSON}})}}_writeMapNote(e,t,r,n){if(null==t)return;const{geometry:i,symbol:o,popupTemplate:s}=t;if(null==i)return;if(i.type!==r)return void n?.messages?.push(new u.Z("map-notes-layer:invalid-geometry-type",`Geometry "${i.type}" cannot be saved in "${r}" layer`,{graphic:t}));if(null==o)return void n?.messages?.push(new u.Z("map-notes-layer:no-symbol","Skipping map notes with no symbol",{graphic:t}));const l={attributes:{...t.attributes},geometry:i.toJSON(),symbol:o.toJSON()};null!=s&&(l.popupInfo=s.toJSON()),e.push(l)}_normalizeObjectIds(e,t){const r=t.name;let n=(0,I.S)(r,e)+1;const i=new Set;for(const t of e){t.attributes||(t.attributes={});const{attributes:e}=t;(null==e[r]||i.has(e[r]))&&(e[r]=n++),i.add(e[r])}}};(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"capabilities",void 0),(0,n._)([(0,y.r)(["portal-item","web-map"],"capabilities",["layers"])],W.prototype,"readCapabilities",null),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"featureCollections",void 0),(0,n._)([(0,y.r)(["web-map","portal-item"],"featureCollections",["layers"])],W.prototype,"readFeatureCollections",null),(0,n._)([(0,c.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{enabled:!0,target:"featureCollection"}}}}})],W.prototype,"featureCollectionJSON",void 0),(0,n._)([(0,y.r)(["web-map","portal-item"],"featureCollectionJSON",["featureCollection"])],W.prototype,"readLegacyfeatureCollectionJSON",null),(0,n._)([(0,c.Cb)({readOnly:!0,json:{read:!0,write:{enabled:!0,ignoreOrigin:!0}}})],W.prototype,"featureCollectionType",void 0),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"fullExtent",null),(0,n._)([(0,c.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{target:"featureCollection.showLegend",overridePolicy(){return{enabled:null!=this.featureCollectionJSON}}}}}}})],W.prototype,"legendEnabled",void 0),(0,n._)([(0,c.Cb)({type:["show","hide","hide-children"]})],W.prototype,"listMode",void 0),(0,n._)([(0,c.Cb)({type:Number,nonNullable:!0,json:{write:!1}})],W.prototype,"minScale",void 0),(0,n._)([(0,y.r)(["web-map","portal-item"],"minScale",["layers"])],W.prototype,"readMinScale",null),(0,n._)([(0,c.Cb)({type:Number,nonNullable:!0,json:{write:!1}})],W.prototype,"maxScale",void 0),(0,n._)([(0,y.r)(["web-map","portal-item"],"maxScale",["layers"])],W.prototype,"readMaxScale",null),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"multipointLayer",null),(0,n._)([(0,c.Cb)({value:"ArcGISFeatureLayer",type:["ArcGISFeatureLayer"]})],W.prototype,"operationalLayerType",void 0),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"pointLayer",null),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"polygonLayer",null),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"polylineLayer",null),(0,n._)([(0,c.Cb)({type:V.Z})],W.prototype,"spatialReference",void 0),(0,n._)([(0,y.r)(["web-map","portal-item"],"spatialReference",["layers"])],W.prototype,"readSpatialReference",null),(0,n._)([(0,c.Cb)({readOnly:!0,json:{origins:{"web-map":{write:{ignoreOrigin:!0}}}}})],W.prototype,"sublayers",void 0),(0,n._)([(0,y.r)("web-map","sublayers",["layers"])],W.prototype,"readSublayers",null),(0,n._)([(0,h.c)("web-map","sublayers")],W.prototype,"writeSublayers",null),(0,n._)([(0,c.Cb)({readOnly:!0})],W.prototype,"textLayer",null),(0,n._)([(0,c.Cb)()],W.prototype,"title",void 0),(0,n._)([(0,c.Cb)({readOnly:!0,json:{read:!1}})],W.prototype,"type",void 0),W=(0,n._)([(0,f.j)("esri.layers.MapNotesLayer")],W);const K=W},92908:(e,t,r)=>{r.d(t,{S:()=>i,X:()=>n});const n=1;function i(e,t){let r=0;for(const n of t){const t=n.attributes?.[e];"number"==typeof t&&isFinite(t)&&(r=Math.max(r,t))}return r}},54295:(e,t,r)=>{r.d(t,{V:()=>s});var n=r(43697),i=r(5600),o=(r(75215),r(67676),r(80442),r(52011));const s=e=>{let t=class extends e{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._)([(0,i.Cb)({type:String})],t.prototype,"apiKey",null),t=(0,n._)([(0,o.j)("esri.layers.mixins.APIKeyMixin")],t),t}},17287:(e,t,r)=>{r.d(t,{Y:()=>a});var n=r(43697),i=r(92604),o=r(5600),s=(r(75215),r(67676),r(80442),r(52011)),l=r(66677);const a=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,l.Qc)(this.url);if(null!=e&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,l.Nm)(e,i.Z.getLogger(this)))}};return(0,n._)([(0,o.Cb)()],t.prototype,"title",null),(0,n._)([(0,o.Cb)({type:String})],t.prototype,"url",null),t=(0,n._)([(0,s.j)("esri.layers.mixins.ArcGISService")],t),t}},17017:(e,t,r)=>{r.d(t,{N:()=>s});var n=r(43697),i=r(5600),o=(r(75215),r(67676),r(80442),r(52011));const s=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,n._)([(0,i.Cb)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,n._)([(0,o.j)("esri.layers.mixins.CustomParametersMixin")],t),t}},34760:(e,t,r)=>{r.d(t,{Q:()=>w});var n=r(43697),i=r(92604),o=r(95330),s=r(5600),l=r(90578),a=(r(67676),r(80442),r(52011)),p=r(82960),u=r(46791),c=(r(66643),r(20102),r(26258),r(87538));const d=new u.Z,y=new WeakMap;function f(e){(function(e){return null!=e&&"object"==typeof e&&"refreshInterval"in e&&"refresh"in e})(e)&&d.push(new WeakRef(e))}function h(e,t){return Number.isFinite(e)&&Number.isFinite(t)?t<=0?e:h(t,e%t):0}let m=0,g=0;function b(){const e=Date.now();let t=!1;for(const r of d){const n=r.deref();n?n.refreshInterval&&e-(y.get(n)??0)+5>=6e4*n.refreshInterval&&(y.set(n,e),n.refresh(e)):t=!0}if(t)for(let e=d.length-1;e>=0;e--)d.at(e).deref()||d.removeAt(e)}(0,c.EH)((()=>{const e=Date.now();let t=0;for(const r of d){const n=r.deref();n&&(t=h(Math.round(6e4*n.refreshInterval),t),n.refreshInterval?y.get(n)||y.set(n,e):y.delete(n))}if(t!==g){if(g=t,clearInterval(m),0===g)return void(m=0);m=setInterval(b,g)}}));const w=e=>{let t=class extends e{constructor(...e){super(...e),this.refreshInterval=0,this.refreshTimestamp=0,this._debounceHasDataChanged=(0,o.Ds)((()=>this.hasDataChanged())),this.when().then((()=>{this.destroyed||f(this)}),(()=>{}))}destroy(){!function(e){const t=d.find((t=>t.deref()===e));t&&d.remove(t)}(this)}castRefreshInterval(e){return e>=.1?e:e<=0?0:.1}get refreshParameters(){return{_ts:this.refreshTimestamp||null}}refresh(e=Date.now()){(0,o.R8)(this._debounceHasDataChanged()).then((t=>{t&&this._set("refreshTimestamp",e),this.emit("refresh",{dataChanged:t})}),(e=>{i.Z.getLogger(this).error(e),this.emit("refresh",{dataChanged:!1,error:e})}))}async hasDataChanged(){return!0}get test(){const e=this;return{set refreshInterval(t){e._set("refreshInterval",t)}}}};return(0,n._)([(0,s.Cb)({type:Number,json:{write:!0,origins:{"web-scene":{write:{enabled:!0,layerContainerTypes:p.C}}}}})],t.prototype,"refreshInterval",void 0),(0,n._)([(0,l.p)("refreshInterval")],t.prototype,"castRefreshInterval",null),(0,n._)([(0,s.Cb)({readOnly:!0})],t.prototype,"refreshTimestamp",void 0),(0,n._)([(0,s.Cb)({readOnly:!0})],t.prototype,"refreshParameters",null),t=(0,n._)([(0,a.j)("esri.layers.mixins.RefreshableLayer")],t),t}},70082:(e,t,r)=>{r.d(t,{Z:()=>c});var n=r(43697),i=r(2368),o=r(35454),s=r(96674),l=r(5600),a=(r(75215),r(67676),r(80442),r(52011));const p=new o.X({esriFeatureEditToolAutoCompletePolygon:"auto-complete-polygon",esriFeatureEditToolCircle:"circle",esriFeatureEditToolEllipse:"ellipse",esriFeatureEditToolFreehand:"freehand",esriFeatureEditToolLine:"line",esriFeatureEditToolNone:"none",esriFeatureEditToolPoint:"point",esriFeatureEditToolPolygon:"polygon",esriFeatureEditToolRectangle:"rectangle",esriFeatureEditToolArrow:"arrow",esriFeatureEditToolTriangle:"triangle",esriFeatureEditToolLeftArrow:"left-arrow",esriFeatureEditToolRightArrow:"right-arrow",esriFeatureEditToolUpArrow:"up-arrow",esriFeatureEditToolDownArrow:"down-arrow"});let u=class extends((0,i.J)(s.wq)){constructor(e){super(e),this.name=null,this.description=null,this.drawingTool=null,this.prototype=null,this.thumbnail=null}};(0,n._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"name",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"description",void 0),(0,n._)([(0,l.Cb)({json:{read:p.read,write:p.write}})],u.prototype,"drawingTool",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"prototype",void 0),(0,n._)([(0,l.Cb)({json:{write:!0}})],u.prototype,"thumbnail",void 0),u=(0,n._)([(0,a.j)("esri.layers.support.FeatureTemplate")],u);const c=u},16451:(e,t,r)=>{r.d(t,{Z:()=>y});var n=r(43697),i=r(2368),o=r(96674),s=r(5600),l=(r(75215),r(67676),r(80442),r(71715)),a=r(52011),p=r(30556),u=r(72729),c=r(70082);let d=class extends((0,i.J)(o.wq)){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,u.im)(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._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"id",void 0),(0,n._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"name",void 0),(0,n._)([(0,s.Cb)({json:{write:!0}})],d.prototype,"domains",void 0),(0,n._)([(0,l.r)("domains")],d.prototype,"readDomains",null),(0,n._)([(0,p.c)("domains")],d.prototype,"writeDomains",null),(0,n._)([(0,s.Cb)({type:[c.Z],json:{write:!0}})],d.prototype,"templates",void 0),d=(0,n._)([(0,a.j)("esri.layers.support.FeatureType")],d);const y=d},1231:(e,t,r)=>{r.d(t,{Z:()=>m});var n,i=r(43697),o=r(35454),s=r(96674),l=r(5600),a=r(75215),p=(r(67676),r(80442),r(36030)),u=r(71715),c=r(52011),d=r(72729),y=r(86719);const f=new o.X({binary:"binary",coordinate:"coordinate",countOrAmount:"count-or-amount",dateAndTime:"date-and-time",description:"description",locationOrPlaceName:"location-or-place-name",measurement:"measurement",nameOrTitle:"name-or-title",none:"none",orderedOrRanked:"ordered-or-ranked",percentageOrRatio:"percentage-or-ratio",typeOrCategory:"type-or-category",uniqueIdentifier:"unique-identifier"});let h=n=class extends s.wq{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=void 0,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let r=null;try{r=t?JSON.parse(t):null}catch(e){}return r?.value??null}readValueType(e,{description:t}){let r=null;try{r=t?JSON.parse(t):null}catch(e){}return r?f.fromJSON(r.fieldValueType):null}clone(){return new n({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain&&this.domain.clone()||null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],h.prototype,"alias",void 0),(0,i._)([(0,l.Cb)({type:[String,Number],json:{write:{allowNull:!0}}})],h.prototype,"defaultValue",void 0),(0,i._)([(0,l.Cb)()],h.prototype,"description",void 0),(0,i._)([(0,u.r)("description")],h.prototype,"readDescription",null),(0,i._)([(0,l.Cb)({types:d.V5,json:{read:{reader:d.im},write:!0}})],h.prototype,"domain",void 0),(0,i._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],h.prototype,"editable",void 0),(0,i._)([(0,l.Cb)({type:a.z8,json:{write:{overridePolicy:e=>({enabled:Number.isFinite(e)})}}})],h.prototype,"length",void 0),(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],h.prototype,"name",void 0),(0,i._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],h.prototype,"nullable",void 0),(0,i._)([(0,p.J)(y.v)],h.prototype,"type",void 0),(0,i._)([(0,l.Cb)()],h.prototype,"valueType",void 0),(0,i._)([(0,u.r)("valueType",["description"])],h.prototype,"readValueType",null),(0,i._)([(0,l.Cb)({type:Boolean,json:{read:!1}})],h.prototype,"visible",void 0),h=n=(0,i._)([(0,c.j)("esri.layers.support.Field")],h);const m=h},99514:(e,t,r)=>{r.d(t,{Z:()=>a});var n=r(20102),i=r(96674),o=r(92604),s=r(69165),l=r(25031);class a{static fromJSON(e){return new a(e.fields,e.timeZoneByFieldName)}static fromLayer(e){return new a(e.fields??[],d(e))}static fromLayerJSON(e){return new a(e.fields??[],d(e))}constructor(e=[],t){this._fieldsMap=new Map,this._normalizedFieldsMap=new Map,this._dateFieldsSet=new Set,this._numericFieldsSet=new Set,this._requiredFields=null,this.dateFields=[],this.numericFields=[],this.fields=e||[],this._timeZoneByFieldName=t?new Map(t):null;const r=[];for(const e of this.fields){const t=e?.name,n=u(t);if(t&&n){const i=p(t);this._fieldsMap.set(t,e),this._fieldsMap.set(i,e),this._normalizedFieldsMap.set(n,e),r.push(`${i}:${e.type}:${this._timeZoneByFieldName?.get(t)}`),(0,s.y2)(e)?(this.dateFields.push(e),this._dateFieldsSet.add(e)):(0,s.H7)(e)&&(this._numericFieldsSet.add(e),this.numericFields.push(e)),(0,s.Dl)(e)||(0,s.Se)(e)||(e.editable=null==e.editable||!!e.editable,e.nullable=null==e.nullable||!!e.nullable)}}r.sort(),this.uid=r.join()}get requiredFields(){if(!this._requiredFields){this._requiredFields=[];for(const e of this.fields)(0,s.Dl)(e)||(0,s.Se)(e)||e.nullable||void 0!==(0,s.os)(e)||this._requiredFields.push(e)}return this._requiredFields}equals(e){return this.uid===e?.uid}has(e){return null!=this.get(e)}get(e){if(!e)return;let t=this._fieldsMap.get(e);return t||(t=this._fieldsMap.get(p(e))??this._normalizedFieldsMap.get(u(e)),t&&this._fieldsMap.set(e,t),t)}getTimeZone(e){const t=this.get(e&&"string"!=typeof e?e.name:e);return t?this._timeZoneByFieldName?this._timeZoneByFieldName.get(t.name):"date"===t.type||"esriFieldTypeDate"===t.type?(o.Z.getLogger("esri.layers.support.FieldsIndex").error(new n.Z("getTimeZone:no-timezone-information",`no time zone information for field '${t.name}'`)),l.pt):c.has(t.type)?l._4:null:null}isDateField(e){return this._dateFieldsSet.has(this.get(e))}isTimeOnlyField(e){return(0,s.sX)(this.get(e))}isNumericField(e){return this._numericFieldsSet.has(this.get(e))}normalizeFieldName(e){return this.get(e)?.name??void 0}toJSON(){return{fields:this.fields.map((e=>(0,i.AK)(e)?e.toJSON():e)),timeZoneByFieldName:this._timeZoneByFieldName?Array.from(this._timeZoneByFieldName.entries()):null}}}function p(e){return e.trim().toLowerCase()}function u(e){return(0,s.q6)(e)?.toLowerCase()??""}const c=new Set(["time-only","date-only","timestamp-offset","esriFieldTypeDateOnly","esriFieldTypeTimeOnly","esriFieldTypeTimestampOffset"]);function d(e){const t=new Map;if(!e.fields)return t;const r=!0===e.datesInUnknownTimezone,{timeInfo:n,editFieldsInfo:i}=e,o=(n?"startField"in n?n.startField:n.startTimeField:"")??"",s=(n?"endField"in n?n.endField:n.endTimeField:"")??"",a=function(e){return"dateFieldsTimeZone"in e}(e)?e.dateFieldsTimeZone??null:e.dateFieldsTimeReference?(0,l.Jv)(e.dateFieldsTimeReference):null,u=i?function(e){return"timeZone"in e}(i)?i.timeZone??a:i.dateFieldsTimeReference?(0,l.Jv)(i.dateFieldsTimeReference):a??l.pt:null,d=n?function(e){return"timeZone"in e}(n)?n.timeZone??a:n.timeReference?(0,l.Jv)(n.timeReference):a:null,y=new Map([[p(i?.creationDateField??""),u],[p(i?.editDateField??""),u],[p(o),d],[p(s),d]]);for(const{name:n,type:i}of e.fields)if(c.has(i))t.set(n,l._4);else if("date"!==i&&"esriFieldTypeDate"!==i)t.set(n,null);else if(r)t.set(n,l._4);else{const e=y.get(p(n??""))??a;t.set(n,e)}return t}},56765:(e,t,r)=>{r.d(t,{Z:()=>u});var n,i=r(43697),o=r(46791),s=r(96674),l=r(5600),a=(r(75215),r(67676),r(80442),r(52011));let p=n=class extends s.wq{constructor(e){super(e),this.floorField=null,this.viewAllMode=!1,this.viewAllLevelIds=new o.Z}clone(){return new n({floorField:this.floorField,viewAllMode:this.viewAllMode,viewAllLevelIds:this.viewAllLevelIds})}};(0,i._)([(0,l.Cb)({type:String,json:{write:!0}})],p.prototype,"floorField",void 0),(0,i._)([(0,l.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllMode",void 0),(0,i._)([(0,l.Cb)({json:{read:!1,write:!1}})],p.prototype,"viewAllLevelIds",void 0),p=n=(0,i._)([(0,a.j)("esri.layers.support.LayerFloorInfo")],p);const u=p},72729:(e,t,r)=>{r.d(t,{im:()=>T,V5:()=>C}),r(80442);var n,i=r(43697),o=r(22974),s=r(5600),l=(r(75215),r(36030)),a=r(52011),p=r(96674);r(67676);let u=n=class extends p.wq{constructor(e){super(e),this.name=null,this.code=null}clone(){return new n({name:this.name,code:this.code})}};(0,i._)([(0,s.Cb)({type:String,json:{write:!0}})],u.prototype,"name",void 0),(0,i._)([(0,s.Cb)({type:[String,Number],json:{write:!0}})],u.prototype,"code",void 0),u=n=(0,i._)([(0,a.j)("esri.layers.support.CodedValue")],u);const c=new(r(35454).X)({inherited:"inherited",codedValue:"coded-value",range:"range"});let d=class extends p.wq{constructor(e){super(e),this.name=null,this.type=null}};(0,i._)([(0,s.Cb)({type:String,json:{write:!0}})],d.prototype,"name",void 0),(0,i._)([(0,l.J)(c)],d.prototype,"type",void 0),d=(0,i._)([(0,a.j)("esri.layers.support.Domain")],d);const y=d;var f;let h=f=class extends y{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const r=String(e);this.codedValues.some((e=>(String(e.code)===r&&(t=e.name),!!t)))}return t}clone(){return new f({codedValues:(0,o.d9)(this.codedValues),name:this.name})}};(0,i._)([(0,s.Cb)({type:[u],json:{write:!0}})],h.prototype,"codedValues",void 0),(0,i._)([(0,l.J)({codedValue:"coded-value"})],h.prototype,"type",void 0),h=f=(0,i._)([(0,a.j)("esri.layers.support.CodedValueDomain")],h);const m=h;var g;r(92604),r(20102);let b=g=class extends y{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,i._)([(0,l.J)({inherited:"inherited"})],b.prototype,"type",void 0),b=g=(0,i._)([(0,a.j)("esri.layers.support.InheritedDomain")],b);const w=b;var S;let v=S=class extends y{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new S({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,i._)([(0,s.Cb)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,r){t[r]=[this.minValue||0,e]}}}})],v.prototype,"maxValue",void 0),(0,i._)([(0,s.Cb)({json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range?.[0]},write:{target:"range",writer(e,t,r){t[r]=[e,this.maxValue||0]}}}})],v.prototype,"minValue",void 0),(0,i._)([(0,l.J)({range:"range"})],v.prototype,"type",void 0),v=S=(0,i._)([(0,a.j)("esri.layers.support.RangeDomain")],v);const _=v,C={key:"type",base:y,typeMap:{range:v,"coded-value":m,inherited:w}};function T(e){if(!e?.type)return null;switch(e.type){case"range":return _.fromJSON(e);case"codedValue":return m.fromJSON(e);case"inherited":return w.fromJSON(e)}return null}},86719:(e,t,r)=>{r.d(t,{v:()=>n});const n=new(r(35454).X)({esriFieldTypeSmallInteger:"small-integer",esriFieldTypeInteger:"integer",esriFieldTypeSingle:"single",esriFieldTypeDouble:"double",esriFieldTypeLong:"long",esriFieldTypeString:"string",esriFieldTypeDate:"date",esriFieldTypeOID:"oid",esriFieldTypeGeometry:"geometry",esriFieldTypeBlob:"blob",esriFieldTypeRaster:"raster",esriFieldTypeGUID:"guid",esriFieldTypeGlobalID:"global-id",esriFieldTypeXML:"xml",esriFieldTypeBigInteger:"big-integer",esriFieldTypeDateOnly:"date-only",esriFieldTypeTimeOnly:"time-only",esriFieldTypeTimestampOffset:"timestamp-offset"})},54275:(e,t,r)=>{r.d(t,{h:()=>c});var n=r(80442),i=r(66677);function o(e,t,r){return!!l(e,t,r)}function s(e,t,r){return l(e,t,r)}function l(e,t,r){return e&&e.hasOwnProperty(t)?e[t]:r}const a={name:"supportsName",size:"supportsSize",contentType:"supportsContentType",keywords:"supportsKeywords",exifInfo:"supportsExifInfo"};function p(e){const t=e?.supportedSpatialAggregationStatistics?.map((e=>e.toLowerCase()));return{envelope:!!t?.includes("envelopeaggregate"),centroid:!!t?.includes("centroidaggregate"),convexHull:!!t?.includes("convexhullaggregate")}}function u(e,t){const r=e?.supportedOperationsWithCacheHint?.map((e=>e.toLowerCase()));return!!r?.includes(t.toLowerCase())}function c(e,t){return{analytics:d(e),attachment:y(e),data:f(e),metadata:h(e),operations:m(e.capabilities,e,t),query:g(e,t),queryRelated:b(e),queryTopFeatures:w(e),editing:S(e)}}function d(e){return{supportsCacheHint:u(e.advancedQueryCapabilities,"queryAnalytics")}}function y(e){const t=e.attachmentProperties,r={supportsName:!1,supportsSize:!1,supportsContentType:!1,supportsKeywords:!1,supportsExifInfo:!1,supportsCacheHint:u(e.advancedQueryCapabilities,"queryAttachments"),supportsResize:o(e,"supportsAttachmentsResizing",!1)};return t&&Array.isArray(t)&&t.forEach((e=>{const t=a[e.name];t&&(r[t]=!!e.isEnabled)})),r}function f(e){return{isVersioned:o(e,"isDataVersioned",!1),supportsAttachment:o(e,"hasAttachments",!1),supportsM:o(e,"hasM",!1),supportsZ:o(e,"hasZ",!1)}}function h(e){return{supportsAdvancedFieldProperties:o(e,"supportsFieldDescriptionProperty",!1)}}function m(e,t,r){const n=e?e.toLowerCase().split(",").map((e=>e.trim())):[],s=r?(0,i.Qc)(r):null,l=n.includes(null!=s&&"MapServer"===s.serverType?"data":"query"),a=n.includes("editing")&&!t.datesInUnknownTimezone;let p=a&&n.includes("create"),u=a&&n.includes("delete"),c=a&&n.includes("update");const d=n.includes("changetracking"),y=t.advancedQueryCapabilities;return a&&!(p||u||c)&&(p=u=c=!0),{supportsCalculate:o(t,"supportsCalculate",!1),supportsTruncate:o(t,"supportsTruncate",!1),supportsValidateSql:o(t,"supportsValidateSql",!1),supportsAdd:p,supportsDelete:u,supportsEditing:a,supportsChangeTracking:d,supportsQuery:l,supportsQueryAnalytics:o(y,"supportsQueryAnalytic",!1),supportsQueryAttachments:o(y,"supportsQueryAttachments",!1),supportsQueryTopFeatures:o(y,"supportsTopFeaturesQuery",!1),supportsResizeAttachments:o(t,"supportsAttachmentsResizing",!1),supportsSync:n.includes("sync"),supportsUpdate:c,supportsExceedsLimitStatistics:o(t,"supportsExceedsLimitStatistics",!1),supportsAsyncConvert3D:o(t,"supportsAsyncConvert3D",!1)}}function g(e,t){const r=e.advancedQueryCapabilities,l=e.ownershipBasedAccessControlForFeatures,a=e.archivingInfo,c=e.currentVersion,d=t?.includes("MapServer"),y=!d||c>=(0,n.Z)("mapserver-pbf-version-support"),f=(0,i.M8)(t),h=new Set((e.supportedQueryFormats??"").split(",").map((e=>e.toLowerCase().trim())));return{supportsStatistics:o(r,"supportsStatistics",e.supportsStatistics),supportsPercentileStatistics:o(r,"supportsPercentileStatistics",!1),supportsSpatialAggregationStatistics:o(r,"supportsSpatialAggregationStatistics",!1),supportedSpatialAggregationStatistics:p(r),supportsCentroid:o(r,"supportsReturningGeometryCentroid",!1),supportsDistance:o(r,"supportsQueryWithDistance",!1),supportsDistinct:o(r,"supportsDistinct",e.supportsAdvancedQueries),supportsExtent:o(r,"supportsReturningQueryExtent",!1),supportsGeometryProperties:o(r,"supportsReturningGeometryProperties",!1),supportsHavingClause:o(r,"supportsHavingClause",!1),supportsOrderBy:o(r,"supportsOrderBy",e.supportsAdvancedQueries),supportsPagination:o(r,"supportsPagination",!1),supportsQuantization:o(e,"supportsCoordinatesQuantization",!1),supportsQuantizationEditMode:o(e,"supportsQuantizationEditMode",!1),supportsQueryGeometry:o(e,"supportsReturningQueryGeometry",!1),supportsResultType:o(r,"supportsQueryWithResultType",!1),supportsMaxRecordCountFactor:o(r,"supportsMaxRecordCountFactor",!1),supportsSqlExpression:o(r,"supportsSqlExpression",!1),supportsStandardizedQueriesOnly:o(e,"useStandardizedQueries",!1),supportsTopFeaturesQuery:o(r,"supportsTopFeaturesQuery",!1),supportsQueryByAnonymous:o(l,"allowAnonymousToQuery",!0),supportsQueryByOthers:o(l,"allowOthersToQuery",!0),supportsHistoricMoment:o(a,"supportsQueryWithHistoricMoment",!1),supportsFormatPBF:y&&h.has("pbf"),supportsDisjointSpatialRelationship:o(r,"supportsDisjointSpatialRel",!1),supportsCacheHint:o(r,"supportsQueryWithCacheHint",!1)||u(r,"query"),supportsDefaultSpatialReference:o(r,"supportsDefaultSR",!1),supportsCompactGeometry:f,supportsFullTextSearch:o(r,"supportsFullTextSearch",!1),maxRecordCountFactor:s(e,"maxRecordCountFactor",void 0),maxRecordCount:s(e,"maxRecordCount",void 0),standardMaxRecordCount:s(e,"standardMaxRecordCount",void 0),tileMaxRecordCount:s(e,"tileMaxRecordCount",void 0)}}function b(e){const t=e.advancedQueryCapabilities,r=o(t,"supportsAdvancedQueryRelated",!1);return{supportsPagination:o(t,"supportsQueryRelatedPagination",!1),supportsCount:r,supportsOrderBy:r,supportsCacheHint:u(t,"queryRelated")}}function w(e){return{supportsCacheHint:u(e.advancedQueryCapabilities,"queryTopFilter")}}function S(e){const t=e.ownershipBasedAccessControlForFeatures,r=e?e.advancedEditingCapabilities:void 0;return{supportsGeometryUpdate:o(e,"allowGeometryUpdates",!0),supportsGlobalId:o(e,"supportsApplyEditsWithGlobalIds",!1),supportsReturnServiceEditsInSourceSpatialReference:o(e,"supportsReturnServiceEditsInSourceSR",!1),supportsRollbackOnFailure:o(e,"supportsRollbackOnFailureParameter",!1),supportsUpdateWithoutM:o(e,"allowUpdateWithoutMValues",!1),supportsUploadWithItemId:o(e,"supportsAttachmentsByUploadId",!1),supportsDeleteByAnonymous:o(t,"allowAnonymousToDelete",!0),supportsDeleteByOthers:o(t,"allowOthersToDelete",!0),supportsUpdateByAnonymous:o(t,"allowAnonymousToUpdate",!0),supportsUpdateByOthers:o(t,"allowOthersToUpdate",!0),supportsAsyncApplyEdits:o(r,"supportsAsyncApplyEdits",!1),zDefault:s(e,"zDefault",void 0)}}},28694:(e,t,r)=>{r.d(t,{p:()=>i});var n=r(69285);function i(e,t,r){if(!r?.features||!r.hasZ)return;const i=(0,n.k)(r.geometryType,t,e.outSpatialReference);if(null!=i)for(const e of r.features)i(e.geometry)}},74889:(e,t,r)=>{r.d(t,{Z:()=>w});var n,i=r(43697),o=r(66577),s=r(38171),l=r(35454),a=r(96674),p=r(22974),u=r(5600),c=(r(75215),r(71715)),d=r(52011),y=r(30556),f=r(82971),h=r(33955),m=r(1231);const g=new l.X({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh","":null});let b=n=class extends a.wq{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){const r=f.Z.fromJSON(t.spatialReference),n=[];for(let t=0;t<e.length;t++){const i=e[t],o=s.Z.fromJSON(i),l=i.geometry?.spatialReference;null==o.geometry||l||(o.geometry.spatialReference=r);const a=i.aggregateGeometries,p=o.aggregateGeometries;if(a&&null!=p)for(const e in p){const t=p[e],n=a[e],i=n?.spatialReference;null==t||i||(t.spatialReference=r)}n.push(o)}return n}writeGeometryType(e,t,r,n){if(e)return void g.write(e,t,r,n);const{features:i}=this;if(i)for(const e of i)if(null!=e?.geometry)return void g.write(e.geometry.type,t,r,n)}readQueryGeometry(e,t){if(!e)return null;const r=!!e.spatialReference,n=(0,h.im)(e);return n&&!r&&t.spatialReference&&(n.spatialReference=f.Z.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,p.d9)({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,o=this.features,s=this._getQuantizationFunction(this.geometryType,(e=>Math.round((e-n)/t)),(e=>Math.round((i-e)/r)));for(let e=0,t=o.length;e<t;e++)s?.(o[e].geometry)||(o.splice(e,1),e--,t--);return this.transform=e,this}unquantize(){const{geometryType:e,features:t,transform:r}=this;if(!r)return this;const{translate:[n,i],scale:[o,s]}=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 p=this._getHydrationFunction(e,(e=>e*o+n),(e=>i-e*s),l,a);for(const{geometry:e}of t)null!=e&&p&&p(e);return this.transform=null,this}_quantizePoints(e,t,r){let n,i;const o=[];for(let s=0,l=e.length;s<l;s++){const l=e[s];if(s>0){const e=t(l[0]),s=r(l[1]);e===n&&s===i||(o.push([e-n,s-i]),n=e,i=s)}else n=t(l[0]),i=r(l[1]),o.push([n,i])}return o.length>0?o:null}_getQuantizationFunction(e,t,r){return"point"===e?e=>(e.x=t(e.x),e.y=r(e.y),e):"polyline"===e||"polygon"===e?e=>{const n=(0,h.oU)(e)?e.rings:e.paths,i=[];for(let e=0,o=n.length;e<o;e++){const o=n[e],s=this._quantizePoints(o,t,r);s&&i.push(s)}return i.length>0?((0,h.oU)(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 o=(0,h.oU)(e)?e.rings:e.paths;let s,l;for(let e=0,n=o.length;e<n;e++){const n=o[e];for(let e=0,i=n.length;e<i;e++){const i=n[e];e>0?(s+=i[0],l+=i[1]):(s=i[0],l=i[1]),i[0]=t(s),i[1]=r(l)}}if(n&&i)for(let e=0,t=o.length;e<t;e++){const t=o[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=o.length;e<t;e++){const t=o[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=o.length;e<t;e++){const t=o[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 o=e.points;let s,l;for(let e=0,n=o.length;e<n;e++){const n=o[e];e>0?(s+=n[0],l+=n[1]):(s=n[0],l=n[1]),n[0]=t(s),n[1]=r(l)}if(n&&i)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=n(t[2]),t[3]=i(t[3])}else if(n)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=n(t[2])}else if(i)for(let e=0,t=o.length;e<t;e++){const t=o[e];t[2]=i(t[2])}}:null}};(0,i._)([(0,u.Cb)({type:String,json:{write:!0}})],b.prototype,"displayFieldName",void 0),(0,i._)([(0,u.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"exceededTransferLimit",void 0),(0,i._)([(0,u.Cb)({type:[s.Z],json:{write:!0}})],b.prototype,"features",void 0),(0,i._)([(0,c.r)("features")],b.prototype,"readFeatures",null),(0,i._)([(0,u.Cb)({type:[m.Z],json:{write:!0}})],b.prototype,"fields",void 0),(0,i._)([(0,u.Cb)({type:["point","multipoint","polyline","polygon","extent","mesh"],json:{read:{reader:g.read}}})],b.prototype,"geometryType",void 0),(0,i._)([(0,y.c)("geometryType")],b.prototype,"writeGeometryType",null),(0,i._)([(0,u.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"hasM",void 0),(0,i._)([(0,u.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],b.prototype,"hasZ",void 0),(0,i._)([(0,u.Cb)({types:o.qM,json:{write:!0}})],b.prototype,"queryGeometry",void 0),(0,i._)([(0,c.r)("queryGeometry")],b.prototype,"readQueryGeometry",null),(0,i._)([(0,u.Cb)({type:f.Z,json:{write:!0}})],b.prototype,"spatialReference",void 0),(0,i._)([(0,y.c)("spatialReference")],b.prototype,"writeSpatialReference",null),(0,i._)([(0,u.Cb)({json:{write:!0}})],b.prototype,"transform",void 0),b=n=(0,i._)([(0,d.j)("esri.rest.support.FeatureSet")],b),b.prototype.toJSON.isDefaultToJSON=!0;const w=b},11282:(e,t,r)=>{r.d(t,{cv:()=>l,en:()=>s,lA:()=>o}),r(68773),r(40330);var n=r(22974),i=r(17452);function o(e,t){return t?{...t,query:{...e??{},...t.query}}:{query:e}}function s(e){return"string"==typeof e?(0,i.mN)(e):(0,n.d9)(e)}function l(e,t,r){const n={};for(const i in e){if("declaredClass"===i)continue;const o=e[i];if(null!=o&&"function"!=typeof o)if(Array.isArray(o)){n[i]=[];for(let e=0;e<o.length;e++)n[i][e]=l(o[e])}else if("object"==typeof o)if(o.toJSON){const e=o.toJSON(r?.[i]);n[i]=t?e:JSON.stringify(e)}else n[i]=t?o:JSON.stringify(o);else n[i]=o}return n}r(71058)},58333:(e,t,r)=>{r.d(t,{ET:()=>o,I4:()=>i,eG:()=>a,lF:()=>s,lj:()=>u,qP:()=>l,wW:()=>p});const n=[252,146,31,255],i={type:"esriSMS",style:"esriSMSCircle",size:6,color:n,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},o={type:"esriSLS",style:"esriSLSSolid",width:.75,color:n},s={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},l={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},a={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},p={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},u={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5883],{13867:(e,t,i)=>{i.d(t,{z:()=>n});var s=i(69801);class n{constructor(e,t){this._storage=new s.WJ,this.id="",this.name="",this.size=0,this._storage.maxSize=e,this._storage.register(this),t&&this._storage.registerRemoveFunc("",t)}destroy(){this._storage.deregister(this),this._storage.destroy()}put(e,t,i=1){this._storage.put(this,e,t,i,1)}pop(e){return this._storage.pop(this,e)}get(e){return this._storage.get(this,e)}clear(){this._storage.clearAll()}get maxSize(){return this._storage.maxSize}set maxSize(e){this._storage.maxSize=e}resetHitRate(){}}},69801:(e,t,i)=>{i.d(t,{WJ:()=>a,Xq:()=>o});var s,n,r=i(44553);(n=s||(s={}))[n.ALL=0]="ALL",n[n.SOME=1]="SOME";class o{constructor(e,t,i){this.name=e,this._storage=t,this.id=l+++":",this.size=0,this.maxSize=0,this._removeFunc=!1,this._hit=0,this._miss=0,this._storage.register(this),i&&(this._storage.registerRemoveFunc(this.id,i),this._removeFunc=!0)}destroy(){this._storage.clear(this),this._removeFunc&&this._storage.deregisterRemoveFunc(this.id),this._storage.deregister(this),this._storage=null}get hitRate(){return this._hit/(this._hit+this._miss)}get sizeAll(){return this._storage.size}resetHitRate(){this._hit=this._miss=0}put(e,t,i,s=0){this._storage.put(this,e,t,i,s)}get(e){const t=this._storage.get(this,e);return void 0===t?++this._miss:++this._hit,t}peek(e){return this._storage.peek(this,e)}pop(e){const t=this._storage.pop(this,e);return void 0===t?++this._miss:++this._hit,t}updateSize(e,t,i){this._storage.updateSize(this,e,t,i)}clear(){this._storage.clear(this)}clearAll(){this._storage.clearAll()}get performanceInfo(){return this._storage.performanceInfo}resetStats(){this._storage.resetStats()}}class a{get size(){return this._size}constructor(e=10485760){this._maxSize=e,this._db=new Map,this._size=0,this._hit=0,this._miss=0,this._removeFuncs=new r.Z,this._users=new r.Z}destroy(){this.clearAll(),this._removeFuncs.clear(),this._users.clear(),this._db=null}register(e){this._users.push(e)}deregister(e){this._users.removeUnordered(e)}registerRemoveFunc(e,t){this._removeFuncs.push([e,t])}deregisterRemoveFunc(e){this._removeFuncs.filterInPlace((t=>t[0]!==e))}get maxSize(){return this._maxSize}set maxSize(e){this._maxSize=Math.max(e,0),this._checkSizeLimits()}put(e,t,i,n,r){t=e.id+t;const o=this._db.get(t);if(o&&(this._size-=o.size,e.size-=o.size,this._db.delete(t),o.entry!==i&&this._notifyRemove(t,o.entry,s.ALL)),n>this._maxSize)return void this._notifyRemove(t,i,s.ALL);if(void 0===i)return void console.warn("Refusing to cache undefined entry ");if(!n||n<0)return console.warn(`Refusing to cache entry with size ${n} for key ${t}`),void this._notifyRemove(t,i,s.ALL);const a=1+Math.max(r,-3)- -3;this._db.set(t,{entry:i,size:n,lifetime:a,lives:a}),this._size+=n,e.size+=n,this._checkSizeLimits()}updateSize(e,t,i,n){t=e.id+t;const r=this._db.get(t);if(r&&r.entry===i){for(this._size-=r.size,e.size-=r.size;n>this._maxSize;){const e=this._notifyRemove(t,i,s.SOME);if(!(null!=e&&e>0))return void this._db.delete(t);n=e}r.size=n,this._size+=n,e.size+=n,this._checkSizeLimits()}}pop(e,t){t=e.id+t;const i=this._db.get(t);if(i)return this._size-=i.size,e.size-=i.size,this._db.delete(t),++this._hit,i.entry;++this._miss}get(e,t){t=e.id+t;const i=this._db.get(t);if(void 0!==i)return this._db.delete(t),i.lives=i.lifetime,this._db.set(t,i),++this._hit,i.entry;++this._miss}peek(e,t){const i=this._db.get(e.id+t);return i?++this._hit:++this._miss,i?.entry}get performanceInfo(){const e={Size:Math.round(this._size/1048576)+"/"+Math.round(this._maxSize/1048576)+"MB","Hit rate":Math.round(100*this._getHitRate())+"%",Entries:this._db.size.toString()},t={},i=new Array;this._db.forEach(((e,s)=>{const n=e.lifetime;i[n]=(i[n]||0)+e.size,this._users.forAll((i=>{const{id:n,name:r}=i;if(s.startsWith(n)){const i=t[r]||0;t[r]=i+e.size}}))}));const s={};this._users.forAll((e=>{const i=e.name;if("hitRate"in e&&"number"==typeof e.hitRate&&!isNaN(e.hitRate)&&e.hitRate>0){const n=t[i]||0;t[i]=n,s[i]=Math.round(100*e.hitRate)+"%"}else s[i]="0%"}));const n=Object.keys(t);n.sort(((e,i)=>t[i]-t[e])),n.forEach((i=>e[i]=Math.round(t[i]/2**20)+"MB / "+s[i]));for(let t=i.length-1;t>=0;--t){const s=i[t];s&&(e["Priority "+(t+-3-1)]=Math.round(s/this._size*100)+"%")}return e}resetStats(){this._hit=this._miss=0,this._users.forAll((e=>e.resetHitRate()))}clear(e){const t=e.id;this._db.forEach(((e,i)=>{i.startsWith(t)&&(this._size-=e.size,this._db.delete(i),this._notifyRemove(i,e.entry,s.ALL))})),e.size=0}clearAll(){this._db.forEach(((e,t)=>this._notifyRemove(t,e.entry,s.ALL))),this._users.forEach((e=>e.size=0)),this._size=0,this._db.clear()}_getHitRate(){return this._hit/(this._hit+this._miss)}_notifyRemove(e,t,i){let s;return this._removeFuncs.some((n=>{if(e.startsWith(n[0])){const e=n[1](t,i);return"number"==typeof e&&(s=e),!0}return!1})),s}_checkSizeLimits(){if(this._size>this._maxSize)for(const[e,t]of this._db)if(this._purgeItem(e,t),this._size<=.9*this.maxSize)return;this._users.forEach((e=>{if(e.maxSize>0&&e.size>e.maxSize)for(const[t,i]of this._db)if(t.startsWith(e.id)&&(this._purgeItem(t,i,e),e.size<=.9*e.maxSize))return}))}_purgeItem(e,t,i=this._users.find((t=>e.startsWith(t.id)))){if(this._db.delete(e),t.lives<=1){this._size-=t.size,i&&(i.size-=t.size);const n=this._notifyRemove(e,t.entry,s.SOME);null!=n&&n>0&&(this._size+=n,i&&(i.size+=n),t.lives=t.lifetime,t.size=n,this._db.set(e,t))}else--t.lives,this._db.set(e,t)}}let l=0},20188:(e,t,i)=>{function s(e){return null!=a(e)||null!=o(e)}function n(e){return l.test(e)}function r(e){return a(e)??o(e)}function o(e){const t=new Date(e);return function(e,t){if(Number.isNaN(e.getTime()))return!1;let i=!0;if(c&&/\d+\W*$/.test(t)){const e=t.match(/[a-zA-Z]{2,}/);if(e){let t=!1,s=0;for(;!t&&s<=e.length;)t=!u.test(e[s]),s++;i=!t}}return i}(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 i=t.groups,s=+i.year,n=+i.month-1,r=+i.day,o=+(i.hours??"0"),a=+(i.minutes??"0"),u=+(i.seconds??"0");if(o>23)return null;if(a>59)return null;if(u>59)return null;const c=i.ms??"0",h=c?+c.padEnd(3,"0").substring(0,3):0;let d;if(i.isUTC||!i.offsetSign)d=Date.UTC(s,n,r,o,a,u,h);else{const e=+i.offsetHours,t=+i.offsetMinutes;d=6e4*("+"===i.offsetSign?-1:1)*(60*e+t)+Date.UTC(s,n,r,o,a,u,h)}return Number.isNaN(d)?null:d}i.d(t,{mu:()=>n,of:()=>s,sG:()=>r});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})))?$/,u=/^((jan(uary)?)|(feb(ruary)?)|(mar(ch)?)|(apr(il)?)|(may)|(jun(e)?)|(jul(y)?)|(aug(ust)?)|(sep(tember)?)|(oct(ober)?)|(nov(ember)?)|(dec(ember)?)|(am)|(pm)|(gmt)|(utc))$/i,c=!Number.isNaN(new Date("technology 10").getTime())},24133:(e,t,i)=>{i.d(t,{Q:()=>o});var s=i(67676),n=i(44553),r=i(88764);class o{constructor(e=9,t){this._compareMinX=c,this._compareMinY=h,this._toBBox=e=>e,this._maxEntries=Math.max(4,e||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),t&&("function"==typeof t?this._toBBox=t:this._initFormat(t)),this.clear()}destroy(){this.clear(),x.prune(),I.prune(),S.prune(),b.prune()}all(e){this._all(this._data,e)}search(e,t){let i=this._data;const s=this._toBBox;if(_(e,i))for(x.clear();i;){for(let n=0,r=i.children.length;n<r;n++){const r=i.children[n],o=i.leaf?s(r):r;_(e,o)&&(i.leaf?t(r):g(e,o)?this._all(r,t):x.push(r))}i=x.pop()}}collides(e){let t=this._data;const i=this._toBBox;if(!_(e,t))return!1;for(x.clear();t;){for(let s=0,n=t.children.length;s<n;s++){const n=t.children[s],r=t.leaf?i(n):n;if(_(e,r)){if(t.leaf||g(e,r))return!0;x.push(n)}}t=x.pop()}return!1}load(e){if(!e.length)return this;if(e.length<this._minEntries){for(let t=0,i=e.length;t<i;t++)this.insert(e[t]);return this}let t=this._build(e.slice(0,e.length),0,e.length-1,0);if(this._data.children.length)if(this._data.height===t.height)this._splitRoot(this._data,t);else{if(this._data.height<t.height){const e=this._data;this._data=t,t=e}this._insert(t,this._data.height-t.height-1,!0)}else this._data=t;return this}insert(e){return e&&this._insert(e,this._data.height-1),this}clear(){return this._data=new v([]),this}remove(e){if(!e)return this;let t,i=this._data,n=null,r=0,o=!1;const a=this._toBBox(e);for(S.clear(),b.clear();i||S.length>0;){if(i||(i=S.pop(),n=S.data[S.length-1],r=b.pop()??0,o=!0),i.leaf&&(t=(0,s.cq)(i.children,e,i.children.length,i.indexHint),-1!==t))return i.children.splice(t,1),S.push(i),this._condense(S),this;o||i.leaf||!g(i,a)?n?(r++,i=n.children[r],o=!1):i=null:(S.push(i),b.push(r),r=0,n=i,i=i.children[0])}return this}toJSON(){return this._data}fromJSON(e){return this._data=e,this}_all(e,t){let i=e;for(I.clear();i;){if(!0===i.leaf)for(const e of i.children)t(e);else I.pushArray(i.children);i=I.pop()??null}}_build(e,t,i,s){const n=i-t+1;let r=this._maxEntries;if(n<=r){const s=new v(e.slice(t,i+1));return a(s,this._toBBox),s}s||(s=Math.ceil(Math.log(n)/Math.log(r)),r=Math.ceil(n/r**(s-1)));const o=new F([]);o.height=s;const l=Math.ceil(n/r),u=l*Math.ceil(Math.sqrt(r));y(e,t,i,u,this._compareMinX);for(let n=t;n<=i;n+=u){const t=Math.min(n+u-1,i);y(e,n,t,l,this._compareMinY);for(let i=n;i<=t;i+=l){const n=Math.min(i+l-1,t);o.children.push(this._build(e,i,n,s-1))}}return a(o,this._toBBox),o}_chooseSubtree(e,t,i,s){for(;s.push(t),!0!==t.leaf&&s.length-1!==i;){let i,s=1/0,n=1/0;for(let r=0,o=t.children.length;r<o;r++){const o=t.children[r],a=d(o),l=p(e,o)-a;l<n?(n=l,s=a<s?a:s,i=o):l===n&&a<s&&(s=a,i=o)}t=i||t.children[0]}return t}_insert(e,t,i){const s=this._toBBox,n=i?e:s(e);S.clear();const r=this._chooseSubtree(n,this._data,t,S);for(r.children.push(e),u(r,n);t>=0&&S.data[t].children.length>this._maxEntries;)this._split(S,t),t--;this._adjustParentBBoxes(n,S,t)}_split(e,t){const i=e.data[t],s=i.children.length,n=this._minEntries;this._chooseSplitAxis(i,n,s);const r=this._chooseSplitIndex(i,n,s);if(!r)return void console.log(" Error: assertion failed at PooledRBush._split: no valid split index");const o=i.children.splice(r,i.children.length-r),l=i.leaf?new v(o):new F(o);l.height=i.height,a(i,this._toBBox),a(l,this._toBBox),t?e.data[t-1].children.push(l):this._splitRoot(i,l)}_splitRoot(e,t){this._data=new F([e,t]),this._data.height=e.height+1,a(this._data,this._toBBox)}_chooseSplitIndex(e,t,i){let s,n,r;s=n=1/0;for(let o=t;o<=i-t;o++){const t=l(e,0,o,this._toBBox),a=l(e,o,i,this._toBBox),u=m(t,a),c=d(t)+d(a);u<s?(s=u,r=o,n=c<n?c:n):u===s&&c<n&&(n=c,r=o)}return r}_chooseSplitAxis(e,t,i){const s=e.leaf?this._compareMinX:c,n=e.leaf?this._compareMinY:h;this._allDistMargin(e,t,i,s)<this._allDistMargin(e,t,i,n)&&e.children.sort(s)}_allDistMargin(e,t,i,s){e.children.sort(s);const n=this._toBBox,r=l(e,0,t,n),o=l(e,i-t,i,n);let a=f(r)+f(o);for(let s=t;s<i-t;s++){const t=e.children[s];u(r,e.leaf?n(t):t),a+=f(r)}for(let s=i-t-1;s>=t;s--){const t=e.children[s];u(o,e.leaf?n(t):t),a+=f(o)}return a}_adjustParentBBoxes(e,t,i){for(let s=i;s>=0;s--)u(t.data[s],e)}_condense(e){for(let t=e.length-1;t>=0;t--){const i=e.data[t];if(0===i.children.length)if(t>0){const n=e.data[t-1],r=n.children;r.splice((0,s.cq)(r,i,r.length,n.indexHint),1)}else this.clear();else a(i,this._toBBox)}}_initFormat(e){const t=["return a"," - b",";"];this._compareMinX=new Function("a","b",t.join(e[0])),this._compareMinY=new Function("a","b",t.join(e[1])),this._toBBox=new Function("a","return {minX: a"+e[0]+", minY: a"+e[1]+", maxX: a"+e[2]+", maxY: a"+e[3]+"};")}}function a(e,t){l(e,0,e.children.length,t,e)}function l(e,t,i,s,n){n||(n=new v([])),n.minX=1/0,n.minY=1/0,n.maxX=-1/0,n.maxY=-1/0;for(let r,o=t;o<i;o++)r=e.children[o],u(n,e.leaf?s(r):r);return n}function u(e,t){e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY)}function c(e,t){return e.minX-t.minX}function h(e,t){return e.minY-t.minY}function d(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function f(e){return e.maxX-e.minX+(e.maxY-e.minY)}function p(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function m(e,t){const i=Math.max(e.minX,t.minX),s=Math.max(e.minY,t.minY),n=Math.min(e.maxX,t.maxX),r=Math.min(e.maxY,t.maxY);return Math.max(0,n-i)*Math.max(0,r-s)}function g(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function _(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function y(e,t,i,s,n){const o=[t,i];for(;o.length;){const t=o.pop(),i=o.pop();if(t-i<=s)continue;const a=i+Math.ceil((t-i)/s/2)*s;(0,r.q)(e,a,i,t,n),o.push(i,a,a,t)}}const x=new n.Z,I=new n.Z,S=new n.Z,b=new n.Z({deallocator:void 0});class w{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class N extends w{constructor(){super(...arguments),this.height=1,this.indexHint=new s.SO}}class v extends N{constructor(e){super(),this.children=e,this.leaf=!0}}class F extends N{constructor(e){super(),this.children=e,this.leaf=!1}}},14808:(e,t,i)=>{i.d(t,{Qc:()=>c,WU:()=>a,lt:()=>u});var s=i(19153),n=i(70171);const r={ar:[".",","],bg:[","," "],bs:[",","."],ca:[",","."],cs:[","," "],da:[",","."],de:[",","."],"de-ch":[".","’"],el:[",","."],en:[".",","],"en-au":[".",","],es:[",","."],"es-mx":[".",","],et:[","," "],fi:[","," "],fr:[","," "],"fr-ch":[","," "],he:[".",","],hi:[".",",","#,##,##0.###"],hr:[",","."],hu:[","," "],id:[",","."],it:[",","."],"it-ch":[".","’"],ja:[".",","],ko:[".",","],lt:[","," "],lv:[","," "],mk:[",","."],nb:[","," "],nl:[",","."],pl:[","," "],pt:[",","."],"pt-pt":[","," "],ro:[",","."],ru:[","," "],sk:[","," "],sl:[",","."],sr:[",","."],sv:[","," "],th:[".",","],tr:[",","."],uk:[","," "],vi:[",","."],zh:[".",","]};function o(e=(0,n.Kd)()){let t=(e=e.toLowerCase())in r;if(!t){const i=e.split("-");i.length>1&&i[0]in r&&(e=i[0],t=!0),t||(e="en")}const[i,s,o="#,##0.###"]=r[e];return{decimal:i,group:s,pattern:o}}function a(e,t){const i=o((t={...t}).locale);t.customs=i;const s=t.pattern||i.pattern;return isNaN(e)||Math.abs(e)===1/0?null:function(e,t,i){const s=(i=i||{}).customs.group,n=i.customs.decimal,r=t.split(";"),o=r[0];if((t=r[e<0?1:0]||"-"+o).includes("%"))e*=100;else if(t.includes("‰"))e*=1e3;else{if(t.includes("¤"))throw new Error("currency notation not supported");if(t.includes("E"))throw new Error("exponential notation not supported")}const a=l,u=o.match(a);if(!u)throw new Error("unable to find a number expression in pattern: "+t);return!1===i.fractional&&(i.places=0),t.replace(a,function(e,t,i){!0===(i=i||{}).places&&(i.places=0),i.places===1/0&&(i.places=6);const s=t.split("."),n="string"==typeof i.places&&i.places.indexOf(",");let r=i.places;n?r=i.places.substring(n+1):+r>=0||(r=(s[1]||[]).length),i.round<0||(e=Number(e.toFixed(Number(r))));const o=String(Math.abs(e)).split("."),a=o[1]||"";if(s[1]||i.places){n&&(i.places=i.places.substring(0,n));const e=void 0!==i.places?i.places:s[1]&&s[1].lastIndexOf("0")+1;+e>a.length&&(o[1]=a.padEnd(Number(e),"0")),+r<a.length&&(o[1]=a.substr(0,Number(r)))}else o[1]&&o.pop();const l=s[0].replace(",","");let u=l.indexOf("0");-1!==u&&(u=l.length-u,u>o[0].length&&(o[0]=o[0].padStart(u,"0")),l.includes("#")||(o[0]=o[0].substr(o[0].length-u)));let c,h,d=s[0].lastIndexOf(",");if(-1!==d){c=s[0].length-d-1;const e=s[0].substr(0,d);d=e.lastIndexOf(","),-1!==d&&(h=e.length-d-1)}const f=[];for(let e=o[0];e;){const t=e.length-c;f.push(t>0?e.substr(t):e),e=t>0?e.slice(0,t):"",h&&(c=h,h=void 0)}return o[0]=f.reverse().join(i.group||","),o.join(i.decimal||".")}(e,u[0],{decimal:n,group:s,places:i.places,round:i.round}))}(e,s,t)}const l=/[#0,]*[#0](?:\.0*#*)?/;function u(e){const t=o((e=e||{}).locale),i=e.pattern||t.pattern,n=t.group,r=t.decimal;let a=1;if(i.includes("%"))a/=100;else if(i.includes("‰"))a/=1e3;else if(i.includes("¤"))throw new Error("currency notation not supported");const u=i.split(";");1===u.length&&u.push("-"+u[0]);const c=d(u,(t=>(t="(?:"+(0,s.Qs)(t,".")+")").replace(l,(t=>{const i={signed:!1,separator:e.strict?n:[n,""],fractional:e.fractional,decimal:r,exponent:!1},s=t.split(".");let o=e.places;1===s.length&&1!==a&&(s[1]="###"),1===s.length||0===o?i.fractional=!1:(void 0===o&&(o=e.pattern?s[1].lastIndexOf("0")+1:1/0),o&&null==e.fractional&&(i.fractional=!0),!e.places&&+o<s[1].length&&(o+=","+s[1].length),i.places=o);const l=s[0].split(",");return l.length>1&&(i.groupSize=l.pop().length,l.length>1&&(i.groupSize2=l.pop().length)),"("+function(e){"places"in(e=e||{})||(e.places=1/0),"string"!=typeof e.decimal&&(e.decimal="."),"fractional"in e&&!String(e.places).startsWith("0")||(e.fractional=[!0,!1]),"exponent"in e||(e.exponent=[!0,!1]),"eSigned"in e||(e.eSigned=[!0,!1]);const t=h(e),i=d(e.fractional,(t=>{let i="";return t&&0!==e.places&&(i="\\"+e.decimal,e.places===1/0?i="(?:"+i+"\\d+)?":i+="\\d{"+e.places+"}"),i}),!0);let s=t+i;return i&&(s="(?:(?:"+s+")|(?:"+i+"))"),s+d(e.exponent,(t=>t?"([eE]"+h({signed:e.eSigned})+")":""))}(i)+")"}))),!0);return{regexp:c.replaceAll(/[\xa0 ]/g,"[\\s\\xa0]"),group:n,decimal:r,factor:a}}function c(e,t){const i=u(t),s=new RegExp("^"+i.regexp+"$").exec(e);if(!s)return NaN;let n=s[1];if(!s[1]){if(!s[2])return NaN;n=s[2],i.factor*=-1}return n=n.replaceAll(new RegExp("["+i.group+"\\s\\xa0]","g"),"").replace(i.decimal,"."),Number(n)*i.factor}function h(e){return"signed"in(e=e||{})||(e.signed=[!0,!1]),"separator"in e?"groupSize"in e||(e.groupSize=3):e.separator="",d(e.signed,(e=>e?"[-+]":""),!0)+d(e.separator,(t=>{if(!t)return"(?:\\d+)";" "===(t=(0,s.Qs)(t))?t="\\s":" "===t&&(t="\\s\\xa0");const i=e.groupSize,n=e.groupSize2;if(n){const e="(?:0|[1-9]\\d{0,"+(n-1)+"}(?:["+t+"]\\d{"+n+"})*["+t+"]\\d{"+i+"})";return i-n>0?"(?:"+e+"|(?:0|[1-9]\\d{0,"+(i-1)+"}))":e}return"(?:0|[1-9]\\d{0,"+(i-1)+"}(?:["+t+"]\\d{"+i+"})*)"}),!0)}const d=(e,t,i)=>{if(!(e instanceof Array))return t(e);const s=[];for(let i=0;i<e.length;i++)s.push(t(e[i]));return f(s.join("|"),Boolean(i))},f=(e,t)=>"("+(t?"?:":"")+e+")"},17445:(e,t,i)=>{i.d(t,{N1:()=>d,YP:()=>l,Z_:()=>m,gx:()=>u,nn:()=>g,on:()=>h,tX:()=>_}),i(66643),i(46791);var s=i(91460),n=i(50758),r=i(70586),o=i(95330),a=i(26258);function l(e,t,i={}){return c(e,t,i,f)}function u(e,t,i={}){return c(e,t,i,p)}function c(e,t,i={},s){let n=null;const o=i.once?(e,i)=>{s(e)&&((0,r.hw)(n),t(e,i))}:(e,i)=>{s(e)&&t(e,i)};if(n=(0,a.aQ)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return n}function h(e,t,i,o={}){let a=null,u=null,c=null;function h(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function d(e){o.once&&o.once&&(0,r.hw)(c),i(e)}const f=l(e,((e,i)=>{h(),(0,s.vT)(e)&&(a=e,u=(0,s.on)(e,t,d),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return c=(0,n.kB)((()=>{f.remove(),h()})),c}function d(e,t){return function(e,t,i){if((0,o.Hc)(i))return Promise.reject((0,o.zE)());const s=e();if(t?.(s))return Promise.resolve(s);let a=null;function l(){a=(0,r.hw)(a)}return new Promise(((s,r)=>{a=(0,n.AL)([(0,o.fu)(i,(()=>{l(),r((0,o.zE)())})),c(e,(e=>{l(),s(e)}),{sync:!1,once:!0},t??f)])}))}(e,p,t)}function f(e){return!0}function p(e){return!!e}i(87538);const m={sync:!0},g={initial:!0},_={sync:!0,initial:!0}},16306:(e,t,i)=>{i.d(t,{aX:()=>b});var s=i(68773),n=i(20102),r=i(92604),o=i(38913),a=i(58901),l=i(73913),u=i(8744),c=i(40488),h=(i(66577),i(3172)),d=i(33955),f=i(11282),p=i(17452);async function m(e,t,i){const s="string"==typeof e?(0,p.mN)(e):e,n=t[0].spatialReference,r=(0,d.Ji)(t[0]),o={...i,query:{...s.query,f:"json",sr:(0,u.B9)(n),geometries:JSON.stringify((l=t,{geometryType:(0,d.Ji)(l[0]),geometries:l.map((e=>e.toJSON()))}))}},{data:a}=await(0,h.Z)(s.path+"/simplify",o);var l;return function(e,t,i){const s=(0,d.q9)(t);return e.map((e=>{const t=s.fromJSON(e);return t.spatialReference=i,t}))}(a.geometries,r,n)}const g=r.Z.getLogger("esri.geometry.support.normalizeUtils");function _(e){return"polygon"===e[0].type}function y(e){return"polyline"===e[0].type}function x(e,t,i){if(t){const t=function(e,t){if(!(e instanceof a.Z||e instanceof o.Z)){const e="straightLineDensify: the input geometry is neither polyline nor polygon";throw g.error(e),new n.Z(e)}const i=(0,l.x3)(e),s=[];for(const e of i){const i=[];s.push(i),i.push([e[0][0],e[0][1]]);for(let s=0;s<e.length-1;s++){const n=e[s][0],r=e[s][1],o=e[s+1][0],a=e[s+1][1],l=Math.sqrt((o-n)*(o-n)+(a-r)*(a-r)),u=(a-r)/l,c=(o-n)/l,h=l/t;if(h>1){for(let e=1;e<=h-1;e++){const s=e*t,o=c*s+n,a=u*s+r;i.push([o,a])}const e=(l+Math.floor(h-1)*t)/2,s=c*e+n,o=u*e+r;i.push([s,o])}i.push([o,a])}}return function(e){return"polygon"===e.type}(e)?new o.Z({rings:s,spatialReference:e.spatialReference}):new a.Z({paths:s,spatialReference:e.spatialReference})}(e,1e6);e=(0,c.Sx)(t,!0)}return i&&(e=(0,l.Sy)(e,i)),e}function I(e,t,i){if(Array.isArray(e)){const s=e[0];if(s>t){const i=(0,l.XZ)(s,t);e[0]=s+i*(-2*t)}else if(s<i){const t=(0,l.XZ)(s,i);e[0]=s+t*(-2*i)}}else{const s=e.x;if(s>t){const i=(0,l.XZ)(s,t);e=e.clone().offset(i*(-2*t),0)}else if(s<i){const t=(0,l.XZ)(s,i);e=e.clone().offset(t*(-2*i),0)}}return e}function S(e,t){let i=-1;for(let s=0;s<t.cutIndexes.length;s++){const n=t.cutIndexes[s],r=t.geometries[s],o=(0,l.x3)(r);for(let e=0;e<o.length;e++){const t=o[e];t.some((i=>{if(i[0]<180)return!0;{let i=0;for(let e=0;e<t.length;e++){const s=t[e][0];i=s>i?s:i}i=Number(i.toFixed(9));const s=-360*(0,l.XZ)(i,180);for(let i=0;i<t.length;i++){const t=r.getPoint(e,i);r.setPoint(e,i,t.clone().offset(s,0))}return!0}}))}if(n===i){if(_(e))for(const t of(0,l.x3)(r))e[n]=e[n].addRing(t);else if(y(e))for(const t of(0,l.x3)(r))e[n]=e[n].addPath(t)}else i=n,e[n]=r}return e}async function b(e,t,i){if(!Array.isArray(e))return b([e],t);t&&"string"!=typeof t&&g.warn("normalizeCentralMeridian()","The url object is deprecated, use the url string instead");const n="string"==typeof t?t:t?.url??s.default.geometryServiceUrl;let r,p,_,y,w,N,v,F,B=0;const E=[],z=[];for(const t of e)if(null!=t)if(r||(r=t.spatialReference,p=(0,u.C5)(r),_=r.isWebMercator,N=_?102100:4326,y=l.UZ[N].maxX,w=l.UZ[N].minX,v=l.UZ[N].plus180Line,F=l.UZ[N].minus180Line),p)if("mesh"===t.type)z.push(t);else if("point"===t.type)z.push(I(t.clone(),y,w));else if("multipoint"===t.type){const e=t.clone();e.points=e.points.map((e=>I(e,y,w))),z.push(e)}else if("extent"===t.type){const e=t.clone()._normalize(!1,!1,p);z.push(e.rings?new o.Z(e):e)}else if(t.extent){const e=t.extent,i=(0,l.XZ)(e.xmin,w)*(2*y);let s=0===i?t.clone():(0,l.Sy)(t.clone(),i);e.offset(i,0),e.intersects(v)&&e.xmax!==y?(B=e.xmax>B?e.xmax:B,s=x(s,_),E.push(s),z.push("cut")):e.intersects(F)&&e.xmin!==w?(B=e.xmax*(2*y)>B?e.xmax*(2*y):B,s=x(s,_,360),E.push(s),z.push("cut")):z.push(s)}else z.push(t.clone());else z.push(t);else z.push(t);let M=(0,l.XZ)(B,y),T=-90;const Z=M,R=new a.Z;for(;M>0;){const e=360*M-180;R.addPath([[e,T],[e,-1*T]]),T*=-1,M--}if(E.length>0&&Z>0){const t=S(E,await async function(e,t,i,s){const n=(0,f.en)(e),r=t[0].spatialReference,o={...s,responseType:"json",query:{...n.query,f:"json",sr:(0,u.B9)(r),target:JSON.stringify({geometryType:(0,d.Ji)(t[0]),geometries:t}),cutter:JSON.stringify(i)}},a=await(0,h.Z)(n.path+"/cut",o),{cutIndexes:l,geometries:c=[]}=a.data;return{cutIndexes:l,geometries:c.map((e=>{const t=(0,d.im)(e);return t.spatialReference=r,t}))}}(n,E,R,i)),s=[],r=[];for(let i=0;i<z.length;i++){const n=z[i];if("cut"!==n)r.push(n);else{const n=t.shift(),o=e[i];null!=o&&"polygon"===o.type&&o.rings&&o.rings.length>1&&n.rings.length>=o.rings.length?(s.push(n),r.push("simplify")):r.push(_?(0,c.$)(n):n)}}if(!s.length)return r;const o=await m(n,s,i),a=[];for(let e=0;e<r.length;e++){const t=r[e];"simplify"!==t?a.push(t):a.push(_?(0,c.$)(o.shift()):o.shift())}return a}const A=[];for(let e=0;e<z.length;e++){const t=z[e];if("cut"!==t)A.push(t);else{const e=E.shift();A.push(!0===_?(0,c.$)(e):e)}}return A}},73913:(e,t,i)=>{i.d(t,{Sy:()=>l,UZ:()=>o,XZ:()=>a,x3:()=>u});var s=i(58901),n=i(82971),r=i(33955);const o={102100:{maxX:20037508.342788905,minX:-20037508.342788905,plus180Line:new s.Z({paths:[[[20037508.342788905,-20037508.342788905],[20037508.342788905,20037508.342788905]]],spatialReference:n.Z.WebMercator}),minus180Line:new s.Z({paths:[[[-20037508.342788905,-20037508.342788905],[-20037508.342788905,20037508.342788905]]],spatialReference:n.Z.WebMercator})},4326:{maxX:180,minX:-180,plus180Line:new s.Z({paths:[[[180,-180],[180,180]]],spatialReference:n.Z.WGS84}),minus180Line:new s.Z({paths:[[[-180,-180],[-180,180]]],spatialReference:n.Z.WGS84})}};function a(e,t){return Math.ceil((e-t)/(2*t))}function l(e,t){const i=u(e);for(const e of i)for(const i of e)i[0]+=t;return e}function u(e){return(0,r.oU)(e)?e.rings:e.paths}},37549:(e,t,i)=>{i.d(t,{H:()=>a});var s=i(80442),n=i(24133),r=i(24470);const o={minX:0,minY:0,maxX:0,maxY:0};class a{constructor(){this._indexInvalid=!1,this._boundsToLoad=[],this._boundsById=new Map,this._idByBounds=new Map,this._index=new n.Q(9,(0,s.Z)("esri-csp-restrictions")?e=>({minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]}):["[0]","[1]","[2]","[3]"]),this._loadIndex=()=>{if(this._indexInvalid){const e=new Array(this._idByBounds.size);let t=0;this._idByBounds.forEach(((i,s)=>{e[t++]=s})),this._indexInvalid=!1,this._index.clear(),this._index.load(e)}else this._boundsToLoad.length&&(this._index.load(Array.from(new Set(this._boundsToLoad.filter((e=>this._idByBounds.has(e)))))),this._boundsToLoad.length=0)}}get fullBounds(){if(!this._boundsById.size)return null;const e=(0,r.cS)();for(const t of this._boundsById.values())t&&(e[0]=Math.min(t[0],e[0]),e[1]=Math.min(t[1],e[1]),e[2]=Math.max(t[2],e[2]),e[3]=Math.max(t[3],e[3]));return e}get valid(){return!this._indexInvalid}clear(){this._indexInvalid=!1,this._boundsToLoad.length=0,this._boundsById.clear(),this._idByBounds.clear(),this._index.clear()}delete(e){const t=this._boundsById.get(e);this._boundsById.delete(e),t&&(this._idByBounds.delete(t),this._indexInvalid||this._index.remove(t))}forEachInBounds(e,t){this._loadIndex(),function(e,t,i){(function(e){o.minX=e[0],o.minY=e[1],o.maxX=e[2],o.maxY=e[3]})(t),e.search(o,i)}(this._index,e,(e=>t(this._idByBounds.get(e))))}get(e){return this._boundsById.get(e)}has(e){return this._boundsById.has(e)}invalidateIndex(){this._indexInvalid||(this._indexInvalid=!0,this._boundsToLoad.length=0)}set(e,t){if(!this._indexInvalid){const t=this._boundsById.get(e);t&&(this._index.remove(t),this._idByBounds.delete(t))}this._boundsById.set(e,t),t&&(this._idByBounds.set(t,e),this._indexInvalid||(this._boundsToLoad.push(t),this._boundsToLoad.length>5e4&&this._loadIndex()))}}},28972:(e,t,i)=>{i.d(t,{Z:()=>N});var s=i(67676),n=i(20102),r=i(32448),o=i(92604),a=i(60437),l=i(24470),u=i(98732),c=i(37549),h=i(42712);function d(e,t){return e?t?4:3:t?3:2}function f(e,t,i,s,n){if(!t?.lengths.length)return null;const r="upperLeft"===n?.originPosition?-1:1;e.lengths.length&&(e.lengths.length=0),e.coords.length&&(e.coords.length=0);const o=e.coords,a=[],l=i?[Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY]:[Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY],{lengths:u,coords:c}=t,h=d(i,s);let f=0;for(const e of u){const t=p(l,c,f,e,i,s,r);t&&a.push(t),f+=e*h}if(a.sort(((e,t)=>{let s=r*e[2]-r*t[2];return 0===s&&i&&(s=e[4]-t[4]),s})),a.length){let e=6*a[0][2];o[0]=a[0][0]/e,o[1]=a[0][1]/e,i&&(e=6*a[0][4],o[2]=0!==e?a[0][3]/e:0),(o[0]<l[0]||o[0]>l[1]||o[1]<l[2]||o[1]>l[3]||i&&(o[2]<l[4]||o[2]>l[5]))&&(o.length=0)}if(!o.length){const e=t.lengths[0]?m(c,0,u[0],i,s):null;if(!e)return null;o[0]=e[0],o[1]=e[1],i&&e.length>2&&(o[2]=e[2])}return e}function p(e,t,i,s,n,r,o=1){const a=d(n,r);let l=i,u=i+a,c=0,h=0,f=0,p=0,m=0;for(let i=0,r=s-1;i<r;i++,l+=a,u+=a){const i=t[l],s=t[l+1],r=t[l+2],o=t[u],a=t[u+1],d=t[u+2];let g=i*a-o*s;p+=g,c+=(i+o)*g,h+=(s+a)*g,n&&(g=i*d-o*r,f+=(r+d)*g,m+=g),i<e[0]&&(e[0]=i),i>e[1]&&(e[1]=i),s<e[2]&&(e[2]=s),s>e[3]&&(e[3]=s),n&&(r<e[4]&&(e[4]=r),r>e[5]&&(e[5]=r))}if(p*o>0&&(p*=-1),m*o>0&&(m*=-1),!p)return null;const g=[c,h,.5*p];return n&&(g[3]=f,g[4]=.5*m),g}function m(e,t,i,s,n){const r=d(s,n);let o=t,a=t+r,l=0,u=0,c=0,h=0;for(let t=0,n=i-1;t<n;t++,o+=r,a+=r){const t=e[o],i=e[o+1],n=e[o+2],r=e[a],d=e[a+1],f=e[a+2],p=s?_(t,i,n,r,d,f):g(t,i,r,d);if(p)if(l+=p,s){const e=x(t,i,n,r,d,f);u+=p*e[0],c+=p*e[1],h+=p*e[2]}else{const e=y(t,i,r,d);u+=p*e[0],c+=p*e[1]}}return l>0?s?[u/l,c/l,h/l]:[u/l,c/l]:i>0?s?[e[t],e[t+1],e[t+2]]:[e[t],e[t+1]]:null}function g(e,t,i,s){const n=i-e,r=s-t;return Math.sqrt(n*n+r*r)}function _(e,t,i,s,n,r){const o=s-e,a=n-t,l=r-i;return Math.sqrt(o*o+a*a+l*l)}function y(e,t,i,s){return[e+.5*(i-e),t+.5*(s-t)]}function x(e,t,i,s,n,r){return[e+.5*(s-e),t+.5*(n-t),i+.5*(r-i)]}var I=i(70272),S=i(5428);const b={getObjectId:e=>e.objectId,getAttributes:e=>e.attributes,getAttribute:(e,t)=>e.attributes[t],cloneWithGeometry:(e,t)=>new I.u_(t,e.attributes,null,e.objectId),getGeometry:e=>e.geometry,getCentroid:(e,t)=>(null==e.centroid&&(e.centroid=f(new S.Z,e.geometry,t.hasZ,t.hasM)),e.centroid)},w=(0,a.Ue)();class N{constructor(e){this.geometryInfo=e,this._boundsStore=new c.H,this._featuresById=new Map,this._markedIds=new Set,this.events=new r.Z,this.featureAdapter=b}get geometryType(){return this.geometryInfo.geometryType}get hasM(){return this.geometryInfo.hasM}get hasZ(){return this.geometryInfo.hasZ}get numFeatures(){return this._featuresById.size}get fullBounds(){return this._boundsStore.fullBounds}get storeStatistics(){let e=0;return this._featuresById.forEach((t=>{null!=t.geometry&&t.geometry.coords&&(e+=t.geometry.coords.length)})),{featureCount:this._featuresById.size,vertexCount:e/(this.hasZ?this.hasM?4:3:this.hasM?3:2)}}getFullExtent(e){if(null==this.fullBounds)return null;const[t,i,s,n]=this.fullBounds;return{xmin:t,ymin:i,xmax:s,ymax:n,spatialReference:(0,h.S2)(e)}}add(e){this._add(e),this._emitChanged()}addMany(e){for(const t of e)this._add(t);this._emitChanged()}upsertMany(e){const t=e.map((e=>this._upsert(e)));return this._emitChanged(),t.filter(s.pC)}clear(){this._featuresById.clear(),this._boundsStore.clear(),this._emitChanged()}removeById(e){const t=this._featuresById.get(e);return t?(this._remove(t),this._emitChanged(),t):null}removeManyById(e){this._boundsStore.invalidateIndex();for(const t of e){const e=this._featuresById.get(t);e&&this._remove(e)}this._emitChanged()}forEachBounds(e,t){for(const i of e){const e=this._boundsStore.get(i.objectId);e&&t((0,a.JR)(w,e))}}getFeature(e){return this._featuresById.get(e)}has(e){return this._featuresById.has(e)}forEach(e){this._featuresById.forEach((t=>e(t)))}forEachInBounds(e,t){this._boundsStore.forEachInBounds(e,(e=>{t(this._featuresById.get(e))}))}startMarkingUsedFeatures(){this._boundsStore.invalidateIndex(),this._markedIds.clear()}sweep(){let e=!1;this._featuresById.forEach(((t,i)=>{this._markedIds.has(i)||(e=!0,this._remove(t))})),this._markedIds.clear(),e&&this._emitChanged()}_emitChanged(){this.events.emit("changed",void 0)}_add(e){if(!e)return;const t=e.objectId;if(null==t)return void o.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e}));const i=this._featuresById.get(t);let s;if(this._markedIds.add(t),i?(e.displayId=i.displayId,s=this._boundsStore.get(t),this._boundsStore.delete(t)):null!=this.onFeatureAdd&&this.onFeatureAdd(e),!e.geometry?.coords?.length)return this._boundsStore.set(t,null),void this._featuresById.set(t,e);s=(0,u.$)(null!=s?s:(0,l.Ue)(),e.geometry,this.geometryInfo.hasZ,this.geometryInfo.hasM),null!=s&&this._boundsStore.set(t,s),this._featuresById.set(t,e)}_upsert(e){const t=e?.objectId;if(null==t)return o.Z.getLogger("esri.layers.graphics.data.FeatureStore").error(new n.Z("featurestore:invalid-feature","feature id is missing",{feature:e})),null;const i=this._featuresById.get(t);if(!i)return this._add(e),e;this._markedIds.add(t);const{geometry:s,attributes:r}=e;for(const e in r)i.attributes[e]=r[e];return s&&(i.geometry=s,this._boundsStore.set(t,(0,u.$)((0,l.Ue)(),s,this.geometryInfo.hasZ,this.geometryInfo.hasM)??null)),i}_remove(e){null!=this.onFeatureRemove&&this.onFeatureRemove(e);const t=e.objectId;return this._markedIds.delete(t),this._boundsStore.delete(t),this._featuresById.delete(t),e}}},27793:(e,t,i)=>{i.r(t),i.d(t,{default:()=>G}),i(66577);var s=i(3172),n=i(66643),r=i(20188),o=i(20102),a=i(92604),l=i(95330),u=i(17452),c=i(73615),h=i(37455),d=i(8744),f=i(40488),p=i(70272),m=i(5428),g=i(28972),_=i(37427),y=i(3489),x=i(14808),I=i(69165);const S=/^\s*"([\S\s]*)"\s*$/,b=/""/g,w="\n",N=[","," ",";","|","\t"];function*v(e,t,i){let s=0;for(;s<=e.length;){const n=e.indexOf(t,s),r=e.substring(s,n>-1?n:void 0);s+=r.length+t.length,i&&!r.trim()||(yield r)}}function F(e){const t=e.includes("\r\n")?"\r\n":w;return v(e,t,!0)}function B(e,t){return v(e,t,!1)}function E(e,t,i){e=e.trim(),t=t?.trim();const s=[],n=Array.from(new Set([i?.delimiter,...N])).filter((e=>null!=e));for(const i of n){const n=T(e,i).length,r=T(t,i).length??n;n>1&&s.push({weight:Math.min(n,r),delimiter:i})}const r=s.sort((({weight:e},{weight:t})=>t-e)).map((({delimiter:e})=>e));for(const t of r){const s=R(M(e,t).names,i?.longitudeField,i?.latitudeField);if(s.longitudeFieldName&&s.latitudeFieldName)return{delimiter:t,locationInfo:s}}return{delimiter:r[0],locationInfo:null}}function*z(e,t,i,s=(()=>Object.create(null))){const n=F(e);n.next();let r="",o="",a=0,l=s(),u=0;e:for(const e of n){const n=B(e,i);for(const e of n)if(r+=o+e,o="",a+=Z(e),a%2==0){if(a>0){const e=S.exec(r);if(!e){l=s(),u=0,r="",a=0;continue e}l[t[u]]=e[1].replaceAll(b,'"'),u++}else l[t[u]]=r,u++;r="",a=0}else o=i;0===a?(yield l,l=s(),u=0):o=w}}function M(e,t){const i=T(e,t).filter((e=>null!=e)),s=i.map((e=>(0,I.q6)(e)));for(let e=s.length-1;e>=0;e--)s[e]||(s.splice(e,1),i.splice(e,1));return{names:s,aliases:i}}function T(e,t){if(!e?.length)return[];const i=[];let s="",n="",r=0;const o=B(e,t);for(const e of o)if(s+=n+e,n="",r+=Z(e),r%2==0){if(r>0){const e=S.exec(s);e&&i.push(e[1].replaceAll(b,'"'))}else i.push(s);s="",r=0}else n=t;return i}function Z(e){let t=0,i=0;for(i=e.indexOf('"',i);i>=0;)t++,i=e.indexOf('"',i+1);return t}function R(e,t,i){t=(0,I.q6)(t)?.toLowerCase(),i=(0,I.q6)(i)?.toLowerCase();const s=e.map((e=>e.toLowerCase())),n=t?e[s.indexOf(t)]:null,r=i?e[s.indexOf(i)]:null;return{longitudeFieldName:n||e[s.indexOf(O.find((e=>s.includes(e))))],latitudeFieldName:r||e[s.indexOf(X.find((e=>s.includes(e))))]}}function A(e){if(!e.length)return"string";const t=/[^+\-.,0-9]/;return e.map((e=>{if(""!==e){if(!t.test(e)){let t=L(e);if(!isNaN(t))return/[.,]/.test(e)||!Number.isInteger(t)||t>214783647||t<-214783648?"double":"integer";if(e.includes("E")){if(t=Number(e),!Number.isNaN(t))return"double";if(e.includes(",")&&(e=e.replace(",","."),t=Number(e),!Number.isNaN(t)))return"double"}}return(0,r.of)(e)?"date":"string"}})).reduce(((e,t)=>void 0===e?t:void 0===t?e:e===t?t:"string"===e||"string"===t?"string":"double"===e||"double"===t?"double":void 0))}const L=function(){const e=(0,x.lt)(),t=new RegExp("^"+e.regexp+"$"),i=new RegExp("["+e.group+"\\s\\xa0]","g"),s=e.factor;return n=>{const r=t.exec(n);if(e.factor=s,!r)return NaN;let o=r[1];if(!r[1]){if(!r[2])return NaN;o=r[2],e.factor*=-1}return o=o.replace(i,"").replace(e.decimal,"."),+o*e.factor}}(),X=["lat","latitude","latitude83","latdecdeg","lat_dd","y","ycenter","point_y"],O=["lon","lng","long","longitude","longitude83","longdecdeg","long_dd","x","xcenter","point_x"];var Y=i(25278),C=i(99514),q=i(25031),k=i(82971);const j=(0,Y.bU)("esriGeometryPoint"),P=["csv"],D=[0,0];class U{constructor(e,t){this.x=e,this.y=t}}class G{constructor(){this._queryEngine=null,this._snapshotFeatures=async e=>{const t=await this._fetch(e);return this._createFeatures(t)}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t={}){this._loadOptions=e;const[i]=await Promise.all([this._fetch(t.signal),this._checkProjection(e?.parsingOptions?.spatialReference)]),s=function(e,t){const i=t.parsingOptions||{},s={delimiter:i.delimiter,layerDefinition:null,locationInfo:{latitudeFieldName:i.latitudeField,longitudeFieldName:i.longitudeField}},n=s.layerDefinition={name:(0,u.vt)(t.url,P)||"csv",dateFieldsTimeReference:{timeZoneIANA:q.pt},drawingInfo:j,geometryType:"esriGeometryPoint",objectIdField:null,fields:[],timeInfo:i.timeInfo,extent:{xmin:Number.POSITIVE_INFINITY,ymin:Number.POSITIVE_INFINITY,xmax:Number.NEGATIVE_INFINITY,ymax:Number.NEGATIVE_INFINITY,spatialReference:i.spatialReference||{wkid:4326}}},r=F(e),a=r.next().value?.trim(),l=r.next().value?.trim();if(!a)throw new o.Z("csv-layer:empty-csv","CSV is empty",{csv:e});const{delimiter:c,locationInfo:h}=E(a,l,i);if(!c)throw new o.Z("csv-layer:invalid-delimiter","Unable to detect the delimiter from CSV",{firstLine:a,secondLine:l,parsingOptions:i});if(!h)throw new o.Z("csv-layer:location-fields-not-found","Unable to identify latitude and longitude fields from the CSV file",{firstLine:a,secondLine:l,parsingOptions:i});s.locationInfo=h,s.delimiter=c;const{names:d,aliases:f}=M(a,c),p=function(e,t,i,s,n){const r=[],o=z(e,i,t),a=[];for(const e of o){if(10===a.length)break;a.push(e)}for(let e=0;e<i.length;e++){const t=i[e],o=s[e];if(t===n.longitudeFieldName||t===n.latitudeFieldName)r.push({name:t,type:"esriFieldTypeDouble",alias:o});else{let e;switch(A(a.map((e=>e[t])))){case"integer":e="esriFieldTypeInteger";break;case"double":e="esriFieldTypeDouble";break;case"date":e="esriFieldTypeDate";break;default:e="esriFieldTypeString"}r.push({name:t,type:e,alias:o,length:(0,I.ZR)(e)})}}return r}(e,s.delimiter,d,f,s.locationInfo);if(i.fields?.length){const e=new C.Z(i.fields);for(const t of p){const i=e.get(t.name);i&&Object.assign(t,i)}}if(!p.some((e=>"esriFieldTypeOID"===e.type&&(n.objectIdField=e.name,!0)))){const e={name:"__OBJECTID",alias:"__OBJECTID",type:"esriFieldTypeOID",editable:!1,nullable:!1};n.objectIdField=e.name,p.unshift(e)}n.fields=p;const m=new C.Z(n.fields);if(s.locationInfo&&(s.locationInfo.latitudeFieldName=m.get(s.locationInfo.latitudeFieldName).name,s.locationInfo.longitudeFieldName=m.get(s.locationInfo.longitudeFieldName).name),n.timeInfo){const e=n.timeInfo;if(e.startTimeField){const t=m.get(e.startTimeField);t?(e.startTimeField=t.name,t.type="esriFieldTypeDate"):e.startTimeField=null}if(e.endTimeField){const t=m.get(e.endTimeField);t?(e.endTimeField=t.name,t.type="esriFieldTypeDate"):e.endTimeField=null}if(e.trackIdField){const t=m.get(e.trackIdField);e.trackIdField=t?t.name:null}e.startTimeField||e.endTimeField||(n.timeInfo=null)}return s}(i,e);this._locationInfo=s.locationInfo,this._delimiter=s.delimiter,this._queryEngine=this._createQueryEngine(s);const n=await this._createFeatures(i);this._queryEngine.featureStore.addMany(n);const{fullExtent:r,timeExtent:a}=await this._queryEngine.fetchRecomputedExtents();if(s.layerDefinition.extent=r,a){const{start:e,end:t}=a;s.layerDefinition.timeInfo.timeExtent=[e,t]}return s}async applyEdits(){throw new o.Z("csv-layer:editing-not-supported","applyEdits() is not supported on CSVLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForIds(e,t.signal)}async queryExtent(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForExtent(e,t.signal)}async querySnapping(e,t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForSnapping(e,t.signal)}async refresh(e){this._loadOptions.customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,n.vr)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,l.D_)(e)||a.Z.getLogger("esri.layers.CSVLayer").error(new o.Z("csv-layer:refresh","An error occurred during refresh",{error:e}))})),await this._waitSnapshotComplete();const{fullExtent:t,timeExtent:i}=await this._queryEngine.fetchRecomputedExtents();return{extent:t,timeExtent:i}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _fetch(e){const{url:t,customParameters:i}=this._loadOptions;if(!t)throw new o.Z("csv-layer:invalid-source","url not defined");const n=(0,u.mN)(t);return(await(0,s.Z)(n.path,{query:{...n.query,...i},responseType:"text",signal:e})).data}_createQueryEngine(e){const{objectIdField:t,fields:i,extent:s,timeInfo:n}=e.layerDefinition,r=new g.Z({geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1});return new y.q({fieldsIndex:C.Z.fromLayerJSON({fields:i,dateFieldsTimeReference:{timeZoneIANA:q.pt}}),geometryType:"esriGeometryPoint",hasM:!1,hasZ:!1,timeInfo:n,objectIdField:t,spatialReference:s.spatialReference||{wkid:4326},cacheSpatialQueries:!0,featureStore:r})}async _createFeatures(e){const{latitudeFieldName:t,longitudeFieldName:i}=this._locationInfo,{objectIdField:s,fieldsIndex:n,spatialReference:o}=this._queryEngine;let a=[];const l=[],u=n.fields.filter((e=>e.name!==s)).map((e=>e.name));let g=0;const _={};for(const e of n.fields)if("esriFieldTypeOID"!==e.type&&"esriFieldTypeGlobalID"!==e.type){const t=(0,I.os)(e);void 0!==t&&(_[e.name]=t)}const y=z(e,u,this._delimiter,(0,Y.Dm)(_,s));for(const e of y){const o=this._parseCoordinateValue(e[t]),u=this._parseCoordinateValue(e[i]);if(null!=u&&null!=o&&!isNaN(o)&&!isNaN(u)){e[t]=o,e[i]=u;for(const s in e)if(s!==t&&s!==i)if(n.isDateField(s))e[s]=(0,r.sG)(e[s]);else if(n.isNumericField(s)){const t=L(e[s]);isNaN(t)?e[s]=null:e[s]=t}e[s]=g,g++,a.push(new U(u,o)),l.push(e)}}if(!(0,d.fS)({wkid:4326},o))if((0,d.sS)(o))for(const e of a)[e.x,e.y]=(0,f.hG)(e.x,e.y,D);else a=(0,c.projectMany)(h.N,a,k.Z.WGS84,o,null,null);const x=[];for(let e=0;e<a.length;e++){const{x:t,y:i}=a[e],n=l[e];n[s]=e+1,x.push(new p.u_(new m.Z([],[t,i]),n,null,n[s]))}return x}_parseCoordinateValue(e){if(null==e||""===e)return null;let t=L(e);return(isNaN(t)||Math.abs(t)>181)&&(t=parseFloat(e)),t}async _checkProjection(e){try{await(0,_._W)(d.Zn,e)}catch{throw new o.Z("csv-layer:projection-not-supported","Projection not supported")}}}},25278:(e,t,i)=>{i.d(t,{Dm:()=>c,Hq:()=>h,MS:()=>d,bU:()=>a});var s=i(80442),n=i(22974),r=i(61159),o=i(58333);function a(e){return{renderer:{type:"simple",symbol:"esriGeometryPoint"===e||"esriGeometryMultipoint"===e?o.I4:"esriGeometryPolyline"===e?o.ET:o.lF}}}const l=/^[_$a-zA-Z][_$a-zA-Z0-9]*$/;let u=1;function c(e,t){if((0,s.Z)("esri-csp-restrictions"))return()=>({[t]:null,...e});try{let i=`this.${t} = null;`;for(const t in e)i+=`this${l.test(t)?`.${t}`:`["${t}"]`} = ${JSON.stringify(e[t])};`;const s=new Function(`\n return class AttributesClass$${u++} {\n constructor() {\n ${i};\n }\n }\n `)();return()=>new s}catch(i){return()=>({[t]:null,...e})}}function h(e={}){return[{name:"New Feature",description:"",prototype:{attributes:(0,n.d9)(e)}}]}function d(e,t){return{analytics:{supportsCacheHint:!1},attachment:null,data:{isVersioned:!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,supportsQueryAnalytics:!1,supportsQueryAttachments:!1,supportsQueryTopFeatures:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsUpdate:t,supportsExceedsLimitStatistics:!0,supportsAsyncConvert3D:!1},query:r.g,queryRelated:{supportsCount:!0,supportsOrderBy:!0,supportsPagination:!0,supportsCacheHint:!1},queryTopFeatures:{supportsCacheHint:!1},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}}}},11282:(e,t,i)=>{i.d(t,{cv:()=>a,en:()=>o,lA:()=>r}),i(68773),i(40330);var s=i(22974),n=i(17452);function r(e,t){return t?{...t,query:{...e??{},...t.query}}:{query:e}}function o(e){return"string"==typeof e?(0,n.mN)(e):(0,s.d9)(e)}function a(e,t,i){const s={};for(const n in e){if("declaredClass"===n)continue;const r=e[n];if(null!=r&&"function"!=typeof r)if(Array.isArray(r)){s[n]=[];for(let e=0;e<r.length;e++)s[n][e]=a(r[e])}else if("object"==typeof r)if(r.toJSON){const e=r.toJSON(i?.[n]);s[n]=t?e:JSON.stringify(e)}else s[n]=t?r:JSON.stringify(r);else s[n]=r}return s}i(71058)},58333:(e,t,i)=>{i.d(t,{ET:()=>r,I4:()=>n,eG:()=>l,lF:()=>o,lj:()=>c,qP:()=>a,wW:()=>u});const s=[252,146,31,255],n={type:"esriSMS",style:"esriSMSCircle",size:6,color:s,outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[153,153,153,255]}},r={type:"esriSLS",style:"esriSLSSolid",width:.75,color:s},o={type:"esriSFS",style:"esriSFSSolid",color:[252,146,31,196],outline:{type:"esriSLS",style:"esriSLSSolid",width:.75,color:[255,255,255,191]}},a={type:"esriTS",color:[255,255,255,255],font:{family:"arial-unicode-ms",size:10,weight:"bold"},horizontalAlignment:"center",kerning:!0,haloColor:[0,0,0,255],haloSize:1,rotated:!1,text:"",xoffset:0,yoffset:0,angle:0},l={type:"esriSMS",style:"esriSMSCircle",color:[0,0,0,255],outline:null,size:10.5},u={type:"esriSLS",style:"esriSLSSolid",color:[0,0,0,255],width:1.5},c={type:"esriSFS",style:"esriSFSSolid",color:[0,0,0,255],outline:null}}}]);
|