@arcgis/core 4.27.0-rc.2 → 4.27.0-rc.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{a8565d1c676f3bfbcebb.js → 002fe1ec63ea33e6972d.js} +1 -1
- package/assets/esri/core/workers/chunks/09e677ca7532a281d262.js +1 -0
- package/assets/esri/core/workers/chunks/0f7ddb063ee0664f2fca.js +1 -0
- package/assets/esri/core/workers/chunks/17ab08f60764244b2cf8.js +1 -0
- package/assets/esri/core/workers/chunks/1aa8dd317ecd3c41e0ea.js +1 -0
- package/assets/esri/core/workers/chunks/28c67c98039503b62e6e.js +1 -0
- package/assets/esri/core/workers/chunks/{2446e336b1f7256d4fde.js → 2c587ed66e2586cccb8d.js} +1 -1
- package/assets/esri/core/workers/chunks/3767b9e7660873b018c2.js +1 -0
- package/assets/esri/core/workers/chunks/{00c7b9fb375c9a934158.js → 38c6452dc9cf18e8bca8.js} +1 -1
- package/assets/esri/core/workers/chunks/39ae4b9b766f674bc6f2.js +1 -0
- package/assets/esri/core/workers/chunks/45629ff775e77234b227.js +1 -0
- package/assets/esri/core/workers/chunks/{16db0bc87d87a7313dc4.js → 4806df402845c717c842.js} +1 -1
- package/assets/esri/core/workers/chunks/4884432d80e9af947449.js +1 -0
- package/assets/esri/core/workers/chunks/4a4f14a3d8da270059c4.js +1 -0
- package/assets/esri/core/workers/chunks/588cd91d08cec5207be1.js +1 -0
- package/assets/esri/core/workers/chunks/{83e3d104886b48f00397.js → 633c00c02a81397fc8df.js} +1 -1
- package/assets/esri/core/workers/chunks/{efb96aefe979a0f5c632.js → 640e8ac3498be30c6614.js} +1 -1
- package/assets/esri/core/workers/chunks/642c5a93c0a454bdd115.js +1 -0
- package/assets/esri/core/workers/chunks/{14145959a3dab1437818.js → 6627f1bc9ee6b620e3aa.js} +1 -1
- package/assets/esri/core/workers/chunks/{33901eb1574e46abd9af.js → 6c213768715c52625855.js} +1 -1
- package/assets/esri/core/workers/chunks/{5e6471dd2a08e66b47d0.js → 6e4940fe3bba014c921b.js} +57 -58
- package/assets/esri/core/workers/chunks/{170bdbdb4e21bf91a17f.js → 6eaa7a51efde2dd4a5a4.js} +1 -1
- package/assets/esri/core/workers/chunks/{0407bf97ad621c89a734.js → 6f724f75f85dc3989d60.js} +1 -1
- package/assets/esri/core/workers/chunks/{2bdc63395c7466ce1641.js → 7053c2f5a958d4c8629b.js} +1 -1
- package/assets/esri/core/workers/chunks/{4c35c663528f710e8c78.js → 79cb672c85ea29e8484a.js} +1 -1
- package/assets/esri/core/workers/chunks/82939ead43848a13f765.js +1 -0
- package/assets/esri/core/workers/chunks/8b05fb365336cc42fecc.js +1 -0
- package/assets/esri/core/workers/chunks/8b6b963230df56850580.js +1 -0
- package/assets/esri/core/workers/chunks/8eec6da5e862cc33ea2b.js +1 -0
- package/assets/esri/core/workers/chunks/90d8f297d9cb359e071d.js +1 -0
- package/assets/esri/core/workers/chunks/91785144901dfe56c5e2.js +1 -0
- package/assets/esri/core/workers/chunks/{471f6eba213412b82840.js → 927417abea79c955b216.js} +1 -1
- package/assets/esri/core/workers/chunks/9472184ef1432fc55d6b.js +1 -0
- package/assets/esri/core/workers/chunks/{adaa9d4239f4e905d011.js → 9d4bd73dd50400e9d328.js} +1 -1
- package/assets/esri/core/workers/chunks/a324cc07d486061d0d8e.js +1 -0
- package/assets/esri/core/workers/chunks/a40130579791293cefa2.js +1 -0
- package/assets/esri/core/workers/chunks/{3e239bfad611985e50fb.js → a49718c74053314ed741.js} +1 -1
- package/assets/esri/core/workers/chunks/a80a6267d88246ede5d3.js +1 -0
- package/assets/esri/core/workers/chunks/ad2891985e0fe45aa8d2.js +1 -0
- package/assets/esri/core/workers/chunks/afcba35eea836aea98ca.js +1 -0
- package/assets/esri/core/workers/chunks/b3d2e397ea74ebef4423.js +1 -0
- package/assets/esri/core/workers/chunks/b5fb9da45cc9dee286f8.js +1 -0
- package/assets/esri/core/workers/chunks/{f505ebd4bd3bfb6c790d.js → b6a55fdfe16795ebf02c.js} +1 -1
- package/assets/esri/core/workers/chunks/b846d4215210aac9f6ef.js +1 -0
- package/assets/esri/core/workers/chunks/c7dc821db8c14fec24a7.js +1 -0
- package/assets/esri/core/workers/chunks/c9df9a0a4a45f9a53ce9.js +1 -0
- package/assets/esri/core/workers/chunks/{45a4041881e6235d73a2.js → d0a9711f48dfa5fee68a.js} +1 -1
- package/assets/esri/core/workers/chunks/{1f69fb9687de9ebfcf90.js → d4ba894a2583f3930a4f.js} +1 -1
- package/assets/esri/core/workers/chunks/d5dfd3d693d5e393a542.js +1 -0
- package/assets/esri/core/workers/chunks/{74fd2059ddda9083cbcc.js → dc6c97a43d642eeaf477.js} +1 -1
- package/assets/esri/core/workers/chunks/e23ec4f867c4735eec20.js +1 -0
- package/assets/esri/core/workers/chunks/ea16230a0edfc9f756bd.js +1 -0
- package/assets/esri/core/workers/chunks/{2154d395f405be3cd3ba.js → eca0c3d57b3a1e3a14ee.js} +1 -1
- package/assets/esri/core/workers/chunks/ef900614353505afb210.js +1 -0
- package/assets/esri/core/workers/chunks/f36697f6aac782007d1a.js +1 -0
- package/assets/esri/core/workers/chunks/f52054f27619a98b7bb7.js +1 -0
- package/assets/esri/core/workers/chunks/fb7fe307a583b6a22218.js +1 -0
- package/assets/esri/core/workers/chunks/fbd3c78ee8e2219a6c7a.js +1 -0
- package/assets/esri/images/portal/livestreamvideolayer16.png +0 -0
- package/assets/esri/images/portal/{mediaservice16.png → videolayer16.png} +0 -0
- package/assets/esri/themes/base/_View.scss +2 -5
- package/assets/esri/themes/base/widgets/_Feature.scss +12 -4
- package/assets/esri/themes/base/widgets/_FeatureForm.scss +19 -2
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/chunks/DefaultMaterial.glsl.js +42 -42
- package/chunks/Terrain.glsl.js +7 -7
- package/copyright.txt +1 -1
- package/geometry/Mesh.js +1 -1
- package/geometry/support/DoubleArray.js +1 -1
- package/geometry/support/meshUtils/bounds.js +1 -1
- package/geometry/support/meshUtils/georeference.js +1 -1
- package/interfaces.d.ts +87 -3
- package/kernel.js +1 -1
- package/layers/OrientedImageryLayer.js +1 -1
- package/layers/SceneLayer.js +1 -1
- package/layers/VideoLayer.js +1 -1
- package/layers/graphics/controllers/I3SOnDemandController.js +1 -1
- package/layers/graphics/editingSupport.js +1 -1
- package/layers/graphics/sources/FeatureLayerSource.js +1 -1
- package/layers/graphics/sources/OGCFeatureSource.js +1 -1
- package/layers/graphics/sources/support/clientSideDefaults.js +1 -1
- package/layers/graphics/sources/support/uploadAssets.js +1 -1
- package/layers/mixins/ArcGISImageService.js +1 -1
- package/layers/mixins/ImageryTileMixin.js +1 -1
- package/layers/orientedImagery/core/ExposurePoint.js +1 -1
- package/layers/orientedImagery/core/bestImageUtils.js +1 -1
- package/layers/orientedImagery/core/coverageUtils.js +1 -1
- package/layers/orientedImagery/transformations/groundToImageUtils.js +1 -1
- package/layers/orientedImagery/transformations/imageToGroundUtils.js +1 -1
- package/layers/support/SubtypeSublayer.js +1 -1
- package/layers/support/capabilities.js +1 -1
- package/layers/support/editableLayers.js +1 -1
- package/layers/support/layerUtils.js +1 -1
- package/layers/support/serviceCapabilitiesUtils.js +1 -1
- package/layers/video/VideoCameraSensorModel.js +5 -0
- package/layers/video/VideoController.js +1 -1
- package/layers/video/videoUtils.js +1 -1
- package/package.json +1 -1
- package/portal/PortalItem.js +1 -1
- package/renderers/support/colorRampUtils.js +1 -1
- package/request.js +1 -1
- package/rest/support/meshFeatureSet.js +1 -1
- package/smartMapping/labels/bins.js +5 -0
- package/smartMapping/labels/clusters.js +1 -1
- package/smartMapping/labels/support/utils.js +5 -0
- package/smartMapping/support/binningUtils.js +1 -1
- package/support/requestUtils.js +1 -1
- package/support/revision.js +1 -1
- package/views/2d/layers/features/schemaUtils.js +1 -1
- package/views/3d/interactive/editingTools/draw/DrawGraphicTool3D.js +1 -1
- package/views/3d/layers/I3SMeshView3D.js +1 -1
- package/views/3d/layers/I3SMeshViewLabeler.js +1 -1
- package/views/3d/layers/I3SMeshWorkerHandle.js +1 -1
- package/views/3d/layers/SceneLayerWorker.js +1 -1
- package/views/3d/layers/graphics/Graphics3DMeshFillSymbolLayer.js +1 -1
- package/views/3d/layers/i3s/I3SClientMaterialUtil.js +5 -0
- package/views/3d/layers/i3s/I3SClientNodeLoader.js +1 -1
- package/views/3d/layers/i3s/I3SGeometryUtil.js +1 -1
- package/views/3d/layers/i3s/I3SOverrides.js +1 -1
- package/views/3d/terrain/TerrainRenderer.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/default/DefaultMaterialAuxiliaryPasses.glsl.js +19 -20
- package/views/3d/webgl-engine/core/shaderLibrary/shading/ReadShadowMap.glsl.js +2 -2
- package/views/3d/webgl-engine/core/shaderLibrary/terrain/TerrainTexture.glsl.js +9 -9
- package/views/3d/webgl-engine/lib/ShadowMap.js +1 -1
- package/views/3d/webgl-engine/shaders/DefaultMaterial.glsl.js +1 -1
- package/views/DOMContainer.js +1 -1
- package/views/PopupView.js +1 -1
- package/views/ui/DefaultUI.js +1 -1
- package/views/ui/UI.js +1 -1
- package/webmap/initialViewPropertiesUtils.js +1 -1
- package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
- package/widgets/Editor/CreateWorkflow.js +1 -1
- package/widgets/Editor/EditorViewModel.js +1 -1
- package/widgets/Editor/UpdateFeatureWorkflow.js +1 -1
- package/widgets/Editor/UpdateWorkflow.js +1 -1
- package/widgets/Editor/UpdateWorkflowData.js +1 -1
- package/widgets/Editor/workflowUtils.js +1 -1
- package/widgets/Feature/support/featureUtils.js +1 -1
- package/widgets/FeatureForm/FeatureFormViewModel.js +1 -1
- package/widgets/FeatureForm/FormExpressionsManager.js +1 -1
- package/widgets/FeatureForm/RelationshipInput.js +1 -1
- package/widgets/FeatureForm/css.js +1 -1
- package/widgets/FeatureForm.js +1 -1
- package/widgets/FeatureTemplates/FeatureTemplatesViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer.js +1 -1
- package/widgets/Popup.js +1 -1
- package/widgets/UtilityNetworkValidateTopology/UtilityNetworkValidateTopologyViewModel.d.ts +4 -0
- package/widgets/UtilityNetworkValidateTopology/UtilityNetworkValidateTopologyViewModel.js +1 -1
- package/widgets/UtilityNetworkValidateTopology.d.ts +4 -0
- package/widgets/support/geolocationUtils.js +1 -1
- package/assets/esri/core/workers/chunks/0610691a0c0d9fbbd6d2.js +0 -1
- package/assets/esri/core/workers/chunks/0618fb0058f39ecd363f.js +0 -1
- package/assets/esri/core/workers/chunks/0fcb8d408696075338e2.js +0 -1
- package/assets/esri/core/workers/chunks/16e459b16bdd6e1a821b.js +0 -1
- package/assets/esri/core/workers/chunks/1b8074269800b384ecf6.js +0 -1
- package/assets/esri/core/workers/chunks/2b55295590b4a0503749.js +0 -1
- package/assets/esri/core/workers/chunks/3ba2fcb9110230f8790c.js +0 -1
- package/assets/esri/core/workers/chunks/5576858f56314afcb4d5.js +0 -1
- package/assets/esri/core/workers/chunks/5706edf45402dff279a6.js +0 -1
- package/assets/esri/core/workers/chunks/624521961fe1f2c4f2c5.js +0 -1
- package/assets/esri/core/workers/chunks/659b7bad7281c0e2aed3.js +0 -1
- package/assets/esri/core/workers/chunks/6cd248d065f6d1616294.js +0 -1
- package/assets/esri/core/workers/chunks/6f510f28526c73ab453c.js +0 -1
- package/assets/esri/core/workers/chunks/7479dc0c790337af7597.js +0 -1
- package/assets/esri/core/workers/chunks/9326120c750799eb2d28.js +0 -1
- package/assets/esri/core/workers/chunks/99e0cec47e3ef72c1de4.js +0 -1
- package/assets/esri/core/workers/chunks/9c0e1e87790424f42d7e.js +0 -1
- package/assets/esri/core/workers/chunks/9e66af3b1c70cf25fb32.js +0 -1
- package/assets/esri/core/workers/chunks/a1c31bb8c12831539328.js +0 -1
- package/assets/esri/core/workers/chunks/a7fd2a95fde197c06828.js +0 -1
- package/assets/esri/core/workers/chunks/b0cda39b53ecd6c44cd0.js +0 -1
- package/assets/esri/core/workers/chunks/b8e6c64792a512df4c4d.js +0 -1
- package/assets/esri/core/workers/chunks/c08e03165043df67c11b.js +0 -1
- package/assets/esri/core/workers/chunks/c26148d4bfab3b3dfab2.js +0 -1
- package/assets/esri/core/workers/chunks/c96db6b7ce47bd343fdb.js +0 -1
- package/assets/esri/core/workers/chunks/d6b6bb8aecc85d2a3f6b.js +0 -1
- package/assets/esri/core/workers/chunks/d95ca50ca7af4c222036.js +0 -1
- package/assets/esri/core/workers/chunks/da57eba2fe25495ea217.js +0 -1
- package/assets/esri/core/workers/chunks/ee5ee03dd2c7dc940272.js +0 -1
- package/assets/esri/core/workers/chunks/eeaf8010e38b65a101ac.js +0 -1
- package/assets/esri/core/workers/chunks/f235392c56063fbf89c6.js +0 -1
- package/assets/esri/core/workers/chunks/f720967ba8c5486a26a2.js +0 -1
- package/assets/esri/core/workers/chunks/fdd0d3616c97e408b104.js +0 -1
- package/layers/orientedImagery/core/Affixes.js +0 -5
- package/layers/orientedImagery/core/CameraProperties.js +0 -5
- package/layers/orientedImagery/core/ImageProperties.js +0 -5
- package/layers/orientedImagery/core/ImageryTypes.js +0 -5
- package/layers/orientedImagery/core/imageryUtils.js +0 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3230],{66643:(e,t,n)=>{n.d(t,{Ed:()=>l,UI:()=>c,mt:()=>f,q6:()=>d,vr:()=>m});var r=n(43697),o=n(92036),i=n(70586),a=n(95330),s=n(5600),u=n(52011);function l(e,t,n){return(0,a.as)(e.map(((e,r)=>t.apply(n,[e,r]))))}async function c(e,t,n){return(await(0,a.as)(e.map(((e,r)=>t.apply(n,[e,r]))))).map((e=>e.value))}function p(e){return{ok:!0,value:e}}function y(e){return{ok:!1,error:e}}async function d(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return y(e)}}async function f(e){try{return p(await e)}catch(e){return(0,a.r9)(e),y(e)}}function m(e,t){return new h(e,t)}let h=class extends o.Z{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,i.IM)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then((e=>{this._result=p(e),this._cleanup()}),(e=>{this._result=y(e),this._cleanup()})),this._abortHandle=(0,a.fu)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,i.hw)(this._abortHandle),this._abortController=null}};(0,r._)([(0,s.Cb)()],h.prototype,"value",null),(0,r._)([(0,s.Cb)()],h.prototype,"error",null),(0,r._)([(0,s.Cb)()],h.prototype,"finished",null),(0,r._)([(0,s.Cb)()],h.prototype,"promise",void 0),(0,r._)([(0,s.Cb)()],h.prototype,"_result",void 0),h=(0,r._)([(0,u.j)("esri.core.asyncUtils.ReactiveTask")],h)},43230:(e,t,n)=>{n.r(t),n.d(t,{default:()=>h});var r=n(66643),o=n(20102),i=n(92604),a=n(95330),s=n(8744),u=n(98732),l=n(57191),c=n(37427),p=n(66202),y=n(92722),d=n(23095),f=n(51432),m=n(99514);class h{constructor(){this._queryEngine=null,this._customParameters=null,this._snapshotFeatures=async e=>{const{objectIdField:t}=this._queryEngine,n=await(0,f.Bm)(this._getFeatureUrl??"",this._featureType.typeName,this._getFeatureOutputFormat,{customParameters:this._customParameters,dateFields:this._queryEngine.fieldsIndex.dateFields.map((e=>e.name)),signal:e});await(0,y.O3)(n),(0,a.k_)(e);const r=(0,y.lG)(n,{geometryType:this._queryEngine.geometryType,hasZ:!1,objectIdField:t});if(!(0,s.fS)(this._queryEngine.spatialReference,s.Zn))for(const e of r)null!=e.geometry&&(e.geometry=(0,u.GH)((0,c.iV)((0,u.di)(e.geometry,this._queryEngine.geometryType,!1,!1),s.Zn,this._queryEngine.spatialReference)));let o=1;for(const e of r){const n={};(0,d.O0)(this._fieldsIndex,n,e.attributes,!0),e.attributes=n,null==e.attributes[t]&&(e.objectId=e.attributes[t]=o++)}return r}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t){const{getFeatureUrl:n,getFeatureOutputFormat:r,spatialReference:o,fields:i,geometryType:s,featureType:u,objectIdField:c,customParameters:y}=e;this._featureType=u,this._customParameters=y,this._getFeatureUrl=n,this._getFeatureOutputFormat=r,this._fieldsIndex=new m.Z(i),await this._checkProjection(o),(0,a.k_)(t),this._queryEngine=new p.q({fields:i,geometryType:s,hasM:!1,hasZ:!1,objectIdField:c,spatialReference:o,timeInfo:null,featureStore:new l.Z({geometryType:s,hasM:!1,hasZ:!1})});const d=await this._snapshotFeatures(t.signal);return this._queryEngine.featureStore.addMany(d),{extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async applyEdits(){throw new o.Z("wfs-source:editing-not-supported","applyEdits() is not supported on WFSLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),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){return this._customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.vr)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.D_)(e)||i.Z.getLogger("esri.layers.WFSLayer").error(new o.Z("wfs-layer:getfeature-error","An error occurred during the GetFeature request",{error:e}))})),await this._waitSnapshotComplete(),{extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _checkProjection(e){try{await(0,c._W)(s.Zn,e)}catch{throw new o.Z("unsupported-projection","Projection not supported",{spatialReference:e})}}}},92722:(e,t,n)=>{n.d(t,{O3:()=>S,lG:()=>T,my:()=>F,q9:()=>u});var r=n(20102),o=n(70272),i=n(5428),a=n(35671);const s={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function u(e){return s[e]}function*l(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*c(e){if(e)switch(e.type){case"Point":yield e.coordinates;break;case"LineString":case"MultiPoint":yield*e.coordinates;break;case"MultiLineString":case"Polygon":for(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function p(e){for(const t of e)if(t.length>2)return!0;return!1}function y(e){let t=0;for(let n=0;n<e.length;n++){const r=e[n],o=e[(n+1)%e.length];t+=r[0]*o[1]-o[0]*r[1]}return t<=0}function d(e){const t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t),e}function f(e,t,n){switch(t.type){case"LineString":case"MultiPoint":return function(e,t,n){return g(e,t.coordinates,n),e}(e,t,n);case"MultiLineString":return function(e,t,n){for(const r of t.coordinates)g(e,r,n);return e}(e,t,n);case"MultiPolygon":return function(e,t,n){for(const r of t.coordinates){m(e,r[0],n);for(let t=1;t<r.length;t++)h(e,r[t],n)}return e}(e,t,n);case"Point":return function(e,t,n){return b(e,t.coordinates,n),e}(e,t,n);case"Polygon":return function(e,t,n){const r=t.coordinates;m(e,r[0],n);for(let t=1;t<r.length;t++)h(e,r[t],n);return e}(e,t,n)}}function m(e,t,n){const r=d(t);!function(e){return!y(e)}(r)?g(e,r,n):w(e,r,n)}function h(e,t,n){const r=d(t);!function(e){return y(e)}(r)?g(e,r,n):w(e,r,n)}function g(e,t,n){for(const r of t)b(e,r,n);e.lengths.push(t.length)}function w(e,t,n){for(let r=t.length-1;r>=0;r--)b(e,t[r],n);e.lengths.push(t.length)}function b(e,t,n){const[r,o,i]=t;e.coords.push(r,o),n.hasZ&&e.coords.push(i||0)}function _(e){switch(typeof e){case"string":return"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function S(e){if(!e)throw new r.Z("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new r.Z("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:t}=e;if(!t)return;const n="string"==typeof t?t:"name"===t.type?t.properties.name:"EPSG"===t.type?t.properties.code:null,o=new RegExp(".*(CRS84H?|4326)$","i");if(!n||!o.test(n))throw new r.Z("geojson-layer:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:t})}function F(e,t={}){const n=[],r=new Set,o=new Set;let i,s=!1,y=null,d=!1,{geometryType:f=null}=t,m=!1;for(const t of l(e)){const{geometry:e,properties:l,id:h}=t;if((!e||(f||(f=u(e.type)),u(e.type)===f))&&(s||(s=p(c(e))),d||(d=null!=h,d&&(i=typeof h,l&&(y=Object.keys(l).filter((e=>l[e]===h))))),l&&y&&d&&null!=h&&(y.length>1?y=y.filter((e=>l[e]===h)):1===y.length&&(y=l[y[0]]===h?y:[])),!m&&l)){let e=!0;for(const t in l){if(r.has(t))continue;const i=l[t];if(null==i){e=!1,o.add(t);continue}const s=_(i);if("unknown"===s){o.add(t);continue}o.delete(t),r.add(t);const u=(0,a.q6)(t);u&&n.push({name:u,alias:t,type:s})}m=e}}const h=(0,a.q6)(1===y?.length&&y[0]||null)??void 0;if(h)for(const e of n)if(e.name===h&&(0,a.H7)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:f,hasZ:s,objectIdFieldName:h,objectIdFieldType:i,unknownFields:Array.from(o)}}function T(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:r}=t;for(const a of e){const{geometry:e,properties:s,id:l}=a;if(e&&u(e.type)!==n)continue;const c=s||{};let p;r&&(p=c[r],null==l||p||(c[r]=p=l));const y=new o.u_(e?f(new i.Z,e,t):null,c,null,p??void 0);yield y}}(l(e),t))}},51432:(e,t,n)=>{n.d(t,{M8:()=>_,ft:()=>q,FU:()=>j,Bm:()=>D,be:()=>O,eB:()=>R}),n(66577);var r=n(3172),o=n(20102),i=n(66374),a=n(95330),s=n(81271),u=n(44547),l=n(8744),c=n(86973),p=n(92722);function y(e){return function(e){const t=d.exec(e);if(!t?.groups)return null;const n=t.groups,r=+n.year,o=+n.month-1,i=+n.day,a=+(n.hours??"0"),s=+(n.minutes??"0"),u=+(n.seconds??"0");if(a>23)return null;if(s>59)return null;if(u>59)return null;const l=n.ms??"0",c=l?+l.padEnd(3,"0").substring(0,3):0;let p;if(n.isUTC)p=Date.UTC(r,o,i,a,s,u,c);else if(n.offsetSign){const e=+n.offsetHours,t=+n.offsetMinutes;p=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(r,o,i,a,s,u,c)}else p=new Date(r,o,i,a,s,u,c).getTime();return Number.isNaN(p)?null:p}(e)??function(e){const t=new Date(e).getTime();return Number.isNaN(t)?null:t}(e)}const d=/^(?:(?<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})))?$/;var f=n(88724),m=n(1231),h=n(82971),g=n(6570);const w="xlink:href",b="2.0.0",_="__esri_wfs_id__",S="wfs-layer:getWFSLayerTypeInfo-error",F="wfs-layer:empty-service",T="wfs-layer:feature-type-not-found",C="wfs-layer:geojson-not-supported",v="wfs-layer:kvp-encoding-not-supported",x="wfs-layer:malformed-json",E="wfs-layer:unknown-geometry-type",P="wfs-layer:unknown-field-type",k="wfs-layer:unsupported-spatial-reference",N="wfs-layer:unsupported-wfs-version";async function j(e,t){const n=function(e){const t=U(e);(function(e){const t=e.firstElementChild?.getAttribute("version");if(t&&t!==b)throw new o.Z(N,`Unsupported WFS version ${t}. Supported version: ${b}`)})(t),J(t);const n=t.firstElementChild,r=(0,i.Fs)(function(e){return(0,f.H)(e,{FeatureTypeList:{FeatureType:e=>{const t={typeName:"undefined:undefined",name:"",title:"",description:"",extent:null,namespacePrefix:"",namespaceUri:"",supportedSpatialReferences:[]},n=new Set([4326]),r=e=>{const t=parseInt(e.textContent?.match(/(?<wkid>\d+$)/i)?.groups?.wkid??"",10);Number.isNaN(t)||n.add(t)};return(0,f.h)(e,{Name:e=>{const{name:n,prefix:r}=L(e.textContent);t.typeName=`${r}:${n}`,t.name=n,t.namespacePrefix=r,t.namespaceUri=e.lookupNamespaceURI(r)},Abstract:e=>{t.description=e.textContent},Title:e=>{t.title=e.textContent},WGS84BoundingBox:e=>{t.extent=function(e){let t,n,r,o;for(const i of e.children)switch(i.localName){case"LowerCorner":[t,n]=i.textContent.split(" ").map((e=>Number.parseFloat(e)));break;case"UpperCorner":[r,o]=i.textContent.split(" ").map((e=>Number.parseFloat(e)))}return{xmin:t,ymin:n,xmax:r,ymax:o,spatialReference:l.Zn}}(e)},DefaultSRS:r,DefaultCRS:r,OtherSRS:r,OtherCRS:r}),t.title||(t.title=t.name),t.supportedSpatialReferences.push(...n),t}}})}(n));return{operations:V(n),get featureTypes(){return Array.from(r())},readFeatureTypes:r}}((await(0,r.default)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetCapabilities",VERSION:b,...t?.customParameters},signal:t?.signal})).data);return function(e,t){(0,s.$U)(e)&&((0,s.D6)(e,t.operations.DescribeFeatureType.url,!0)&&(t.operations.DescribeFeatureType.url=(0,s.hO)(t.operations.DescribeFeatureType.url)),(0,s.D6)(e,t.operations.GetFeature.url,!0)&&(t.operations.GetFeature.url=(0,s.hO)(t.operations.GetFeature.url)))}(e,n),n}const Z=new Set(["json","application/json","geojson","application/json; subtype=geojson"]);function V(e){let t=!1;const n={GetCapabilities:{url:""},DescribeFeatureType:{url:""},GetFeature:{url:"",outputFormat:null,supportsPagination:!1}};if((0,f.h)(e,{OperationsMetadata:{Operation:e=>{switch(e.getAttribute("name")){case"GetCapabilities":return{DCP:{HTTP:{Get:e=>{n.GetCapabilities.url=e.getAttribute(w)}}}};case"DescribeFeatureType":return{DCP:{HTTP:{Get:e=>{n.DescribeFeatureType.url=e.getAttribute(w)}}}};case"GetFeature":return{DCP:{HTTP:{Get:e=>{n.GetFeature.url=e.getAttribute(w)}}},Parameter:e=>{if("outputFormat"===e.getAttribute("name"))return{AllowedValues:{Value:e=>{const t=e.textContent;t&&Z.has(t.toLowerCase())&&(n.GetFeature.outputFormat=t)}}}}}}},Constraint:e=>{switch(e.getAttribute("name")){case"KVPEncoding":return{DefaultValue:e=>{t="true"===e.textContent.toLowerCase()}};case"ImplementsResultPaging":return{DefaultValue:e=>{n.GetFeature.supportsPagination="true"===e.textContent.toLowerCase()}}}}}}),!t)throw new o.Z(v,"WFS service doesn't support key/value pair (KVP) encoding");if(null==n.GetFeature.outputFormat)throw new o.Z(C,"WFS service doesn't support GeoJSON output format");return n}function q(e,t,n){return(0,i.sE)(e,(e=>n?e.name===t&&e.namespaceUri===n:e.typeName===t||e.name===t))}async function O(e,t,n,r={}){const{featureType:i,extent:s}=await async function(e,t,n,r={}){const{spatialReference:i=h.Z.WGS84}=r,a=e.readFeatureTypes(),s=t?q(a,t,n):a.next().value;if(null==s)throw t?new o.Z(T,`The type '${t}' could not be found in the service`):new o.Z(F,"The service is empty");let c=new g.Z({...s.extent,spatialReference:i});if(!(0,l.fS)(i,l.Zn))try{await(0,u.iQ)(l.Zn,i,void 0,r),c=(0,u.iV)(c,l.Zn)}catch{throw new o.Z(k,"Projection not supported")}return{extent:c,spatialReference:i,featureType:s}}(e,t,n,r),{fields:c,geometryType:p,swapXY:y,objectIdField:d,geometryField:f}=await async function(e,t,n={}){const[r,i]=await(0,a.as)([A(e.operations.DescribeFeatureType.url,t,n),G(e,t,n)]);if(r.error||i.error)throw new o.Z(S,`An error occurred while getting info about the feature type '${t}'`,{error:r.error||i.error});const{fields:s,errors:u}=r.value??{},l=r.value?.geometryType||i.value?.geometryType,c=i.value?.swapXY??!1;if(null==l)throw new o.Z(E,`The geometry type could not be determined for type '${t}`,{typeName:t,geometryType:l,fields:s,errors:u});return{...R(s??[]),geometryType:l,swapXY:c}}(e,i.typeName,r);return{url:e.operations.GetCapabilities.url,name:i.name,namespaceUri:i.namespaceUri,fields:c,geometryField:f,geometryType:p,objectIdField:d,spatialReference:r.spatialReference??h.Z.WGS84,extent:s,swapXY:y,wfsCapabilities:e,customParameters:r.customParameters}}function R(e){const t=e.find((e=>"geometry"===e.type));let n=e.find((e=>"oid"===e.type));return e=e.filter((e=>"geometry"!==e.type)),n||(n=new m.Z({name:_,type:"oid",alias:_}),e.unshift(n)),{geometryField:t?.name??null,objectIdField:n.name,fields:e}}async function G(e,t,n={}){let o,i=!1;const[a,s]=await Promise.all([D(e.operations.GetFeature.url,t,e.operations.GetFeature.outputFormat,{...n,count:1}),(0,r.default)(e.operations.GetFeature.url,{responseType:"text",query:M(t,void 0,{...n,count:1}),signal:n?.signal})]),u="FeatureCollection"===a.type&&a.features[0]?.geometry;if(u){let e;switch(o=c.M.fromJSON((0,p.q9)(u.type)),u.type){case"Point":e=u.coordinates;break;case"LineString":case"MultiPoint":e=u.coordinates[0];break;case"MultiLineString":case"Polygon":e=u.coordinates[0][0];break;case"MultiPolygon":e=u.coordinates[0][0][0]}const t=/<[^>]*pos[^>]*> *(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/.exec(s.data);if(t){const n=e[0].toFixed(3),r=e[1].toFixed(3),o=parseFloat(t[1]).toFixed(3);n===parseFloat(t[2]).toFixed(3)&&r===o&&(i=!0)}}return{geometryType:o,swapXY:i}}async function A(e,t,n){return function(e,t){const{name:n}=L(e),r=U(t);J(r);const a=(0,i.sE)((0,f.H)(r.firstElementChild,{element:e=>({name:e.getAttribute("name"),typeName:L(e.getAttribute("type")).name})}),(({name:e})=>e===n));if(null!=a){const e=(0,i.sE)((0,f.H)(r.firstElementChild,{complexType:e=>e}),(e=>e.getAttribute("name")===a.typeName));if(null!=e)return function(e){const t=[],n=[];let r;const i=(0,f.H)(e,{complexContent:{extension:{sequence:{element:e=>e}}}});for(const a of i){const i=a.getAttribute("name");if(!i)continue;let s,u;if(a.hasAttribute("type")?s=L(a.getAttribute("type")).name:(0,f.h)(a,{simpleType:{restriction:e=>(s=L(e.getAttribute("base")).name,{maxLength:e=>{u=+e.getAttribute("value")}})}}),!s)continue;const l="true"===a.getAttribute("nillable");let c=!1;switch(s.toLowerCase()){case"integer":case"nonpositiveinteger":case"negativeinteger":case"long":case"int":case"short":case"byte":case"nonnegativeinteger":case"unsignedlong":case"unsignedint":case"unsignedshort":case"unsignedbyte":case"positiveinteger":n.push(new m.Z({name:i,alias:i,type:"integer",nullable:l}));break;case"float":case"double":case"decimal":n.push(new m.Z({name:i,alias:i,type:"double",nullable:l}));break;case"boolean":case"string":case"gyearmonth":case"gyear":case"gmonthday":case"gday":case"gmonth":case"anyuri":case"qname":case"notation":case"normalizedstring":case"token":case"language":case"idrefs":case"entities":case"nmtoken":case"nmtokens":case"name":case"ncname":case"id":case"idref":case"entity":case"duration":case"time":n.push(new m.Z({name:i,alias:i,type:"string",nullable:l,length:u??255}));break;case"datetime":case"date":n.push(new m.Z({name:i,alias:i,type:"date",nullable:l,length:u??36}));break;case"pointpropertytype":r="point",c=!0;break;case"multipointpropertytype":r="multipoint",c=!0;break;case"curvepropertytype":case"multicurvepropertytype":case"multilinestringpropertytype":r="polyline",c=!0;break;case"surfacepropertytype":case"multisurfacepropertytype":case"multipolygonpropertytype":r="polygon",c=!0;break;case"geometrypropertytype":case"multigeometrypropertytype":c=!0,t.push(new o.Z(E,`geometry type '${s}' is not supported`,{type:(new XMLSerializer).serializeToString(e)}));break;default:t.push(new o.Z(P,`Unknown field type '${s}'`,{type:(new XMLSerializer).serializeToString(e)}))}c&&n.push(new m.Z({name:i,alias:i,type:"geometry",nullable:l}))}for(const e of n)if("integer"===e.type&&!e.nullable&&I.has(e.name.toLowerCase())){e.type="oid";break}return{geometryType:r,fields:n,errors:t}}(e)}throw new o.Z(T,`Type '${e}' not found in document`,{document:(new XMLSerializer).serializeToString(r)})}(t,(await(0,r.default)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"DescribeFeatureType",VERSION:b,TYPENAME:t,...n?.customParameters},signal:n?.signal})).data)}const I=new Set(["objectid","fid"]);async function D(e,t,n,i){let{data:a}=await(0,r.default)(e,{responseType:"text",query:M(t,n,i),signal:i?.signal});a=a.replaceAll(/": +(-?\d+),(\d+)(,)?/g,'": $1.$2$3');try{if(i?.dateFields?.length){const e=new Set(i.dateFields);return JSON.parse(a,((t,n)=>e.has(t)?y(n):n))}return JSON.parse(a)}catch(e){throw new o.Z(x,"Error while parsing the response",{response:a,error:e})}}function M(e,t,n){return{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:b,TYPENAMES:e,OUTPUTFORMAT:t,SRSNAME:"EPSG:4326",STARTINDEX:n?.startIndex,COUNT:n?.count,...n?.customParameters}}function U(e){return(new DOMParser).parseFromString(e.trim(),"text/xml")}function L(e){const[t,n]=e.split(":");return{prefix:n?t:"",name:n??t}}function J(e){let t="",n="";if((0,f.h)(e.firstElementChild,{Exception:e=>(t=e.getAttribute("exceptionCode"),{ExceptionText:e=>{n=e.textContent}})}),t)throw new o.Z(`wfs-layer:${t}`,n)}},88724:(e,t,n)=>{function r(e,t){if(e&&t)for(const n of e.children)if(n.localName in t){const e=t[n.localName];if("function"==typeof e){const t=e(n);t&&r(n,t)}else r(n,e)}}function*o(e,t){for(const n of e.children)if(n.localName in t){const e=t[n.localName];"function"==typeof e?yield e(n):yield*o(n,e)}}n.d(t,{H:()=>o,h:()=>r})},1231:(e,t,n)=>{n.d(t,{Z:()=>h});var r,o=n(43697),i=n(35454),a=n(96674),s=n(5600),u=n(75215),l=(n(67676),n(80442),n(36030)),c=n(71715),p=n(52011),y=n(72729),d=n(86719);const f=new i.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 m=r=class extends a.wq{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=-1,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?f.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain&&this.domain.clone()||null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,o._)([(0,s.Cb)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"description",void 0),(0,o._)([(0,c.r)("description")],m.prototype,"readDescription",null),(0,o._)([(0,s.Cb)({types:y.V5,json:{read:{reader:y.im},write:!0}})],m.prototype,"domain",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,o._)([(0,s.Cb)({type:u.z8,json:{write:!0}})],m.prototype,"length",void 0),(0,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,o._)([(0,l.J)(d.v)],m.prototype,"type",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"valueType",void 0),(0,o._)([(0,c.r)("valueType",["description"])],m.prototype,"readValueType",null),(0,o._)([(0,s.Cb)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,o._)([(0,p.j)("esri.layers.support.Field")],m);const h=m},72729:(e,t,n)=>{n.d(t,{im:()=>C,V5:()=>T}),n(80442);var r,o=n(43697),i=n(22974),a=n(5600),s=(n(75215),n(36030)),u=n(52011),l=n(96674);n(67676);let c=r=class extends l.wq{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,o._)([(0,a.Cb)({type:[String,Number],json:{write:!0}})],c.prototype,"code",void 0),c=r=(0,o._)([(0,u.j)("esri.layers.support.CodedValue")],c);const p=new(n(35454).X)({inherited:"inherited",codedValue:"coded-value",range:"range"});let y=class extends l.wq{constructor(e){super(e),this.name=null,this.type=null}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],y.prototype,"name",void 0),(0,o._)([(0,s.J)(p)],y.prototype,"type",void 0),y=(0,o._)([(0,u.j)("esri.layers.support.Domain")],y);const d=y;var f;let m=f=class extends d{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some((e=>(String(e.code)===n&&(t=e.name),!!t)))}return t}clone(){return new f({codedValues:(0,i.d9)(this.codedValues),name:this.name})}};(0,o._)([(0,a.Cb)({type:[c],json:{write:!0}})],m.prototype,"codedValues",void 0),(0,o._)([(0,s.J)({codedValue:"coded-value"})],m.prototype,"type",void 0),m=f=(0,o._)([(0,u.j)("esri.layers.support.CodedValueDomain")],m);const h=m;var g;n(92604),n(20102);let w=g=class extends d{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,o._)([(0,s.J)({inherited:"inherited"})],w.prototype,"type",void 0),w=g=(0,o._)([(0,u.j)("esri.layers.support.InheritedDomain")],w);const b=w;var _;let S=_=class extends d{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new _({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,o._)([(0,a.Cb)({type:Number,json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range&&t.range[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]}}}})],S.prototype,"maxValue",void 0),(0,o._)([(0,a.Cb)({type:Number,json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range&&t.range[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]}}}})],S.prototype,"minValue",void 0),(0,o._)([(0,s.J)({range:"range"})],S.prototype,"type",void 0),S=_=(0,o._)([(0,u.j)("esri.layers.support.RangeDomain")],S);const F=S,T={key:"type",base:d,typeMap:{range:S,"coded-value":h,inherited:b}};function C(e){if(!e||!e.type)return null;switch(e.type){case"range":return F.fromJSON(e);case"codedValue":return h.fromJSON(e);case"inherited":return b.fromJSON(e)}return null}}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3230],{66643:(e,t,n)=>{n.d(t,{Ed:()=>l,UI:()=>c,mt:()=>f,q6:()=>d,vr:()=>m});var r=n(43697),o=n(92036),i=n(70586),a=n(95330),s=n(5600),u=n(52011);function l(e,t,n){return(0,a.as)(e.map(((e,r)=>t.apply(n,[e,r]))))}async function c(e,t,n){return(await(0,a.as)(e.map(((e,r)=>t.apply(n,[e,r]))))).map((e=>e.value))}function p(e){return{ok:!0,value:e}}function y(e){return{ok:!1,error:e}}async function d(e){if(null==e)return{ok:!1,error:new Error("no promise provided")};try{return p(await e)}catch(e){return y(e)}}async function f(e){try{return p(await e)}catch(e){return(0,a.r9)(e),y(e)}}function m(e,t){return new h(e,t)}let h=class extends o.Z{get value(){return null!=(e=this._result)&&!0===e.ok?e.value:null;var e}get error(){return null!=(e=this._result)&&!1===e.ok?e.error:null;var e}get finished(){return null!=this._result}constructor(e,t){super({}),this._result=null,this._abortHandle=null,this.abort=()=>{this._abortController=(0,i.IM)(this._abortController)},this.remove=this.abort,this._abortController=new AbortController;const{signal:n}=this._abortController;this.promise=e(n),this.promise.then((e=>{this._result=p(e),this._cleanup()}),(e=>{this._result=y(e),this._cleanup()})),this._abortHandle=(0,a.fu)(t,this.abort)}normalizeCtorArgs(){return{}}destroy(){this.abort()}_cleanup(){this._abortHandle=(0,i.hw)(this._abortHandle),this._abortController=null}};(0,r._)([(0,s.Cb)()],h.prototype,"value",null),(0,r._)([(0,s.Cb)()],h.prototype,"error",null),(0,r._)([(0,s.Cb)()],h.prototype,"finished",null),(0,r._)([(0,s.Cb)()],h.prototype,"promise",void 0),(0,r._)([(0,s.Cb)()],h.prototype,"_result",void 0),h=(0,r._)([(0,u.j)("esri.core.asyncUtils.ReactiveTask")],h)},43230:(e,t,n)=>{n.r(t),n.d(t,{default:()=>h});var r=n(66643),o=n(20102),i=n(92604),a=n(95330),s=n(8744),u=n(98732),l=n(57191),c=n(37427),p=n(66202),y=n(92722),d=n(23095),f=n(51432),m=n(99514);class h{constructor(){this._queryEngine=null,this._customParameters=null,this._snapshotFeatures=async e=>{const{objectIdField:t}=this._queryEngine,n=await(0,f.Bm)(this._getFeatureUrl??"",this._featureType.typeName,this._getFeatureOutputFormat,{customParameters:this._customParameters,dateFields:this._queryEngine.fieldsIndex.dateFields.map((e=>e.name)),signal:e});await(0,y.O3)(n),(0,a.k_)(e);const r=(0,y.lG)(n,{geometryType:this._queryEngine.geometryType,hasZ:!1,objectIdField:t});if(!(0,s.fS)(this._queryEngine.spatialReference,s.Zn))for(const e of r)null!=e.geometry&&(e.geometry=(0,u.GH)((0,c.iV)((0,u.di)(e.geometry,this._queryEngine.geometryType,!1,!1),s.Zn,this._queryEngine.spatialReference)));let o=1;for(const e of r){const n={};(0,d.O0)(this._fieldsIndex,n,e.attributes,!0),e.attributes=n,null==e.attributes[t]&&(e.objectId=e.attributes[t]=o++)}return r}}destroy(){this._queryEngine?.destroy(),this._queryEngine=null}async load(e,t){const{getFeatureUrl:n,getFeatureOutputFormat:r,spatialReference:o,fields:i,geometryType:s,featureType:u,objectIdField:c,customParameters:y}=e;this._featureType=u,this._customParameters=y,this._getFeatureUrl=n,this._getFeatureOutputFormat=r,this._fieldsIndex=new m.Z(i),await this._checkProjection(o),(0,a.k_)(t),this._queryEngine=new p.q({fields:i,geometryType:s,hasM:!1,hasZ:!1,objectIdField:c,spatialReference:o,timeInfo:null,featureStore:new l.Z({geometryType:s,hasM:!1,hasZ:!1})});const d=await this._snapshotFeatures(t.signal);return this._queryEngine.featureStore.addMany(d),{extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async applyEdits(){throw new o.Z("wfs-source:editing-not-supported","applyEdits() is not supported on WFSLayer")}async queryFeatures(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQuery(e,t.signal)}async queryFeatureCount(e={},t={}){return await this._waitSnapshotComplete(),this._queryEngine.executeQueryForCount(e,t.signal)}async queryObjectIds(e={},t={}){return await this._waitSnapshotComplete(),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){return this._customParameters=e,this._snapshotTask?.abort(),this._snapshotTask=(0,r.vr)(this._snapshotFeatures),this._snapshotTask.promise.then((e=>{this._queryEngine.featureStore.clear(),e&&this._queryEngine.featureStore.addMany(e)}),(e=>{this._queryEngine.featureStore.clear(),(0,a.D_)(e)||i.Z.getLogger("esri.layers.WFSLayer").error(new o.Z("wfs-layer:getfeature-error","An error occurred during the GetFeature request",{error:e}))})),await this._waitSnapshotComplete(),{extent:(await this._queryEngine.fetchRecomputedExtents()).fullExtent}}async _waitSnapshotComplete(){if(this._snapshotTask&&!this._snapshotTask.finished){try{await this._snapshotTask.promise}catch{}return this._waitSnapshotComplete()}}async _checkProjection(e){try{await(0,c._W)(s.Zn,e)}catch{throw new o.Z("unsupported-projection","Projection not supported",{spatialReference:e})}}}},92722:(e,t,n)=>{n.d(t,{O3:()=>S,lG:()=>T,my:()=>F,q9:()=>u});var r=n(20102),o=n(70272),i=n(5428),a=n(35671);const s={LineString:"esriGeometryPolyline",MultiLineString:"esriGeometryPolyline",MultiPoint:"esriGeometryMultipoint",Point:"esriGeometryPoint",Polygon:"esriGeometryPolygon",MultiPolygon:"esriGeometryPolygon"};function u(e){return s[e]}function*l(e){switch(e.type){case"Feature":yield e;break;case"FeatureCollection":for(const t of e.features)t&&(yield t)}}function*c(e){if(e)switch(e.type){case"Point":yield e.coordinates;break;case"LineString":case"MultiPoint":yield*e.coordinates;break;case"MultiLineString":case"Polygon":for(const t of e.coordinates)yield*t;break;case"MultiPolygon":for(const t of e.coordinates)for(const e of t)yield*e}}function p(e){for(const t of e)if(t.length>2)return!0;return!1}function y(e){let t=0;for(let n=0;n<e.length;n++){const r=e[n],o=e[(n+1)%e.length];t+=r[0]*o[1]-o[0]*r[1]}return t<=0}function d(e){const t=e[0],n=e[e.length-1];return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]||e.push(t),e}function f(e,t,n){switch(t.type){case"LineString":case"MultiPoint":return function(e,t,n){return g(e,t.coordinates,n),e}(e,t,n);case"MultiLineString":return function(e,t,n){for(const r of t.coordinates)g(e,r,n);return e}(e,t,n);case"MultiPolygon":return function(e,t,n){for(const r of t.coordinates){m(e,r[0],n);for(let t=1;t<r.length;t++)h(e,r[t],n)}return e}(e,t,n);case"Point":return function(e,t,n){return b(e,t.coordinates,n),e}(e,t,n);case"Polygon":return function(e,t,n){const r=t.coordinates;m(e,r[0],n);for(let t=1;t<r.length;t++)h(e,r[t],n);return e}(e,t,n)}}function m(e,t,n){const r=d(t);!function(e){return!y(e)}(r)?g(e,r,n):w(e,r,n)}function h(e,t,n){const r=d(t);!function(e){return y(e)}(r)?g(e,r,n):w(e,r,n)}function g(e,t,n){for(const r of t)b(e,r,n);e.lengths.push(t.length)}function w(e,t,n){for(let r=t.length-1;r>=0;r--)b(e,t[r],n);e.lengths.push(t.length)}function b(e,t,n){const[r,o,i]=t;e.coords.push(r,o),n.hasZ&&e.coords.push(i||0)}function _(e){switch(typeof e){case"string":return"esriFieldTypeString";case"number":return"esriFieldTypeDouble";default:return"unknown"}}function S(e){if(!e)throw new r.Z("geojson-layer:empty","GeoJSON data is empty");if("Feature"!==e.type&&"FeatureCollection"!==e.type)throw new r.Z("geojson-layer:unsupported-geojson-object","missing or not supported GeoJSON object type",{data:e});const{crs:t}=e;if(!t)return;const n="string"==typeof t?t:"name"===t.type?t.properties.name:"EPSG"===t.type?t.properties.code:null,o=new RegExp(".*(CRS84H?|4326)$","i");if(!n||!o.test(n))throw new r.Z("geojson-layer:unsupported-crs","unsupported GeoJSON 'crs' member",{crs:t})}function F(e,t={}){const n=[],r=new Set,o=new Set;let i,s=!1,y=null,d=!1,{geometryType:f=null}=t,m=!1;for(const t of l(e)){const{geometry:e,properties:l,id:h}=t;if((!e||(f||(f=u(e.type)),u(e.type)===f))&&(s||(s=p(c(e))),d||(d=null!=h,d&&(i=typeof h,l&&(y=Object.keys(l).filter((e=>l[e]===h))))),l&&y&&d&&null!=h&&(y.length>1?y=y.filter((e=>l[e]===h)):1===y.length&&(y=l[y[0]]===h?y:[])),!m&&l)){let e=!0;for(const t in l){if(r.has(t))continue;const i=l[t];if(null==i){e=!1,o.add(t);continue}const s=_(i);if("unknown"===s){o.add(t);continue}o.delete(t),r.add(t);const u=(0,a.q6)(t);u&&n.push({name:u,alias:t,type:s})}m=e}}const h=(0,a.q6)(1===y?.length&&y[0]||null)??void 0;if(h)for(const e of n)if(e.name===h&&(0,a.H7)(e)){e.type="esriFieldTypeOID";break}return{fields:n,geometryType:f,hasZ:s,objectIdFieldName:h,objectIdFieldType:i,unknownFields:Array.from(o)}}function T(e,t){return Array.from(function*(e,t={}){const{geometryType:n,objectIdField:r}=t;for(const a of e){const{geometry:e,properties:s,id:l}=a;if(e&&u(e.type)!==n)continue;const c=s||{};let p;r&&(p=c[r],null==l||p||(c[r]=p=l));const y=new o.u_(e?f(new i.Z,e,t):null,c,null,p??void 0);yield y}}(l(e),t))}},51432:(e,t,n)=>{n.d(t,{M8:()=>_,ft:()=>q,FU:()=>j,Bm:()=>D,be:()=>O,eB:()=>R}),n(66577);var r=n(3172),o=n(20102),i=n(66374),a=n(95330),s=n(81271),u=n(44547),l=n(8744),c=n(86973),p=n(92722);function y(e){return function(e){const t=d.exec(e);if(!t?.groups)return null;const n=t.groups,r=+n.year,o=+n.month-1,i=+n.day,a=+(n.hours??"0"),s=+(n.minutes??"0"),u=+(n.seconds??"0");if(a>23)return null;if(s>59)return null;if(u>59)return null;const l=n.ms??"0",c=l?+l.padEnd(3,"0").substring(0,3):0;let p;if(n.isUTC)p=Date.UTC(r,o,i,a,s,u,c);else if(n.offsetSign){const e=+n.offsetHours,t=+n.offsetMinutes;p=6e4*("+"===n.offsetSign?-1:1)*(60*e+t)+Date.UTC(r,o,i,a,s,u,c)}else p=new Date(r,o,i,a,s,u,c).getTime();return Number.isNaN(p)?null:p}(e)??function(e){const t=new Date(e).getTime();return Number.isNaN(t)?null:t}(e)}const d=/^(?:(?<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})))?$/;var f=n(88724),m=n(1231),h=n(82971),g=n(6570);const w="xlink:href",b="2.0.0",_="__esri_wfs_id__",S="wfs-layer:getWFSLayerTypeInfo-error",F="wfs-layer:empty-service",T="wfs-layer:feature-type-not-found",C="wfs-layer:geojson-not-supported",v="wfs-layer:kvp-encoding-not-supported",x="wfs-layer:malformed-json",E="wfs-layer:unknown-geometry-type",P="wfs-layer:unknown-field-type",k="wfs-layer:unsupported-spatial-reference",N="wfs-layer:unsupported-wfs-version";async function j(e,t){const n=function(e){const t=U(e);(function(e){const t=e.firstElementChild?.getAttribute("version");if(t&&t!==b)throw new o.Z(N,`Unsupported WFS version ${t}. Supported version: ${b}`)})(t),J(t);const n=t.firstElementChild,r=(0,i.Fs)(function(e){return(0,f.H)(e,{FeatureTypeList:{FeatureType:e=>{const t={typeName:"undefined:undefined",name:"",title:"",description:"",extent:null,namespacePrefix:"",namespaceUri:"",supportedSpatialReferences:[]},n=new Set([4326]),r=e=>{const t=parseInt(e.textContent?.match(/(?<wkid>\d+$)/i)?.groups?.wkid??"",10);Number.isNaN(t)||n.add(t)};return(0,f.h)(e,{Name:e=>{const{name:n,prefix:r}=L(e.textContent);t.typeName=`${r}:${n}`,t.name=n,t.namespacePrefix=r,t.namespaceUri=e.lookupNamespaceURI(r)},Abstract:e=>{t.description=e.textContent},Title:e=>{t.title=e.textContent},WGS84BoundingBox:e=>{t.extent=function(e){let t,n,r,o;for(const i of e.children)switch(i.localName){case"LowerCorner":[t,n]=i.textContent.split(" ").map((e=>Number.parseFloat(e)));break;case"UpperCorner":[r,o]=i.textContent.split(" ").map((e=>Number.parseFloat(e)))}return{xmin:t,ymin:n,xmax:r,ymax:o,spatialReference:l.Zn}}(e)},DefaultSRS:r,DefaultCRS:r,OtherSRS:r,OtherCRS:r}),t.title||(t.title=t.name),t.supportedSpatialReferences.push(...n),t}}})}(n));return{operations:V(n),get featureTypes(){return Array.from(r())},readFeatureTypes:r}}((await(0,r.default)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"GetCapabilities",VERSION:b,...t?.customParameters},signal:t?.signal})).data);return function(e,t){(0,s.$U)(e)&&((0,s.D6)(e,t.operations.DescribeFeatureType.url,!0)&&(t.operations.DescribeFeatureType.url=(0,s.hO)(t.operations.DescribeFeatureType.url)),(0,s.D6)(e,t.operations.GetFeature.url,!0)&&(t.operations.GetFeature.url=(0,s.hO)(t.operations.GetFeature.url)))}(e,n),n}const Z=new Set(["json","application/json","geojson","application/json; subtype=geojson"]);function V(e){let t=!1;const n={GetCapabilities:{url:""},DescribeFeatureType:{url:""},GetFeature:{url:"",outputFormat:null,supportsPagination:!1}};if((0,f.h)(e,{OperationsMetadata:{Operation:e=>{switch(e.getAttribute("name")){case"GetCapabilities":return{DCP:{HTTP:{Get:e=>{n.GetCapabilities.url=e.getAttribute(w)}}}};case"DescribeFeatureType":return{DCP:{HTTP:{Get:e=>{n.DescribeFeatureType.url=e.getAttribute(w)}}}};case"GetFeature":return{DCP:{HTTP:{Get:e=>{n.GetFeature.url=e.getAttribute(w)}}},Parameter:e=>{if("outputFormat"===e.getAttribute("name"))return{AllowedValues:{Value:e=>{const t=e.textContent;t&&Z.has(t.toLowerCase())&&(n.GetFeature.outputFormat=t)}}}}}}},Constraint:e=>{switch(e.getAttribute("name")){case"KVPEncoding":return{DefaultValue:e=>{t="true"===e.textContent.toLowerCase()}};case"ImplementsResultPaging":return{DefaultValue:e=>{n.GetFeature.supportsPagination="true"===e.textContent.toLowerCase()}}}}}}),!t)throw new o.Z(v,"WFS service doesn't support key/value pair (KVP) encoding");if(null==n.GetFeature.outputFormat)throw new o.Z(C,"WFS service doesn't support GeoJSON output format");return n}function q(e,t,n){return(0,i.sE)(e,(e=>n?e.name===t&&e.namespaceUri===n:e.typeName===t||e.name===t))}async function O(e,t,n,r={}){const{featureType:i,extent:s}=await async function(e,t,n,r={}){const{spatialReference:i=h.Z.WGS84}=r,a=e.readFeatureTypes(),s=t?q(a,t,n):a.next().value;if(null==s)throw t?new o.Z(T,`The type '${t}' could not be found in the service`):new o.Z(F,"The service is empty");let c=new g.Z({...s.extent,spatialReference:i});if(!(0,l.fS)(i,l.Zn))try{await(0,u.initializeProjection)(l.Zn,i,void 0,r),c=(0,u.iV)(c,l.Zn)}catch{throw new o.Z(k,"Projection not supported")}return{extent:c,spatialReference:i,featureType:s}}(e,t,n,r),{fields:c,geometryType:p,swapXY:y,objectIdField:d,geometryField:f}=await async function(e,t,n={}){const[r,i]=await(0,a.as)([A(e.operations.DescribeFeatureType.url,t,n),G(e,t,n)]);if(r.error||i.error)throw new o.Z(S,`An error occurred while getting info about the feature type '${t}'`,{error:r.error||i.error});const{fields:s,errors:u}=r.value??{},l=r.value?.geometryType||i.value?.geometryType,c=i.value?.swapXY??!1;if(null==l)throw new o.Z(E,`The geometry type could not be determined for type '${t}`,{typeName:t,geometryType:l,fields:s,errors:u});return{...R(s??[]),geometryType:l,swapXY:c}}(e,i.typeName,r);return{url:e.operations.GetCapabilities.url,name:i.name,namespaceUri:i.namespaceUri,fields:c,geometryField:f,geometryType:p,objectIdField:d,spatialReference:r.spatialReference??h.Z.WGS84,extent:s,swapXY:y,wfsCapabilities:e,customParameters:r.customParameters}}function R(e){const t=e.find((e=>"geometry"===e.type));let n=e.find((e=>"oid"===e.type));return e=e.filter((e=>"geometry"!==e.type)),n||(n=new m.Z({name:_,type:"oid",alias:_}),e.unshift(n)),{geometryField:t?.name??null,objectIdField:n.name,fields:e}}async function G(e,t,n={}){let o,i=!1;const[a,s]=await Promise.all([D(e.operations.GetFeature.url,t,e.operations.GetFeature.outputFormat,{...n,count:1}),(0,r.default)(e.operations.GetFeature.url,{responseType:"text",query:M(t,void 0,{...n,count:1}),signal:n?.signal})]),u="FeatureCollection"===a.type&&a.features[0]?.geometry;if(u){let e;switch(o=c.M.fromJSON((0,p.q9)(u.type)),u.type){case"Point":e=u.coordinates;break;case"LineString":case"MultiPoint":e=u.coordinates[0];break;case"MultiLineString":case"Polygon":e=u.coordinates[0][0];break;case"MultiPolygon":e=u.coordinates[0][0][0]}const t=/<[^>]*pos[^>]*> *(-?\d+(?:\.\d+)?) (-?\d+(?:\.\d+)?)/.exec(s.data);if(t){const n=e[0].toFixed(3),r=e[1].toFixed(3),o=parseFloat(t[1]).toFixed(3);n===parseFloat(t[2]).toFixed(3)&&r===o&&(i=!0)}}return{geometryType:o,swapXY:i}}async function A(e,t,n){return function(e,t){const{name:n}=L(e),r=U(t);J(r);const a=(0,i.sE)((0,f.H)(r.firstElementChild,{element:e=>({name:e.getAttribute("name"),typeName:L(e.getAttribute("type")).name})}),(({name:e})=>e===n));if(null!=a){const e=(0,i.sE)((0,f.H)(r.firstElementChild,{complexType:e=>e}),(e=>e.getAttribute("name")===a.typeName));if(null!=e)return function(e){const t=[],n=[];let r;const i=(0,f.H)(e,{complexContent:{extension:{sequence:{element:e=>e}}}});for(const a of i){const i=a.getAttribute("name");if(!i)continue;let s,u;if(a.hasAttribute("type")?s=L(a.getAttribute("type")).name:(0,f.h)(a,{simpleType:{restriction:e=>(s=L(e.getAttribute("base")).name,{maxLength:e=>{u=+e.getAttribute("value")}})}}),!s)continue;const l="true"===a.getAttribute("nillable");let c=!1;switch(s.toLowerCase()){case"integer":case"nonpositiveinteger":case"negativeinteger":case"long":case"int":case"short":case"byte":case"nonnegativeinteger":case"unsignedlong":case"unsignedint":case"unsignedshort":case"unsignedbyte":case"positiveinteger":n.push(new m.Z({name:i,alias:i,type:"integer",nullable:l}));break;case"float":case"double":case"decimal":n.push(new m.Z({name:i,alias:i,type:"double",nullable:l}));break;case"boolean":case"string":case"gyearmonth":case"gyear":case"gmonthday":case"gday":case"gmonth":case"anyuri":case"qname":case"notation":case"normalizedstring":case"token":case"language":case"idrefs":case"entities":case"nmtoken":case"nmtokens":case"name":case"ncname":case"id":case"idref":case"entity":case"duration":case"time":n.push(new m.Z({name:i,alias:i,type:"string",nullable:l,length:u??255}));break;case"datetime":case"date":n.push(new m.Z({name:i,alias:i,type:"date",nullable:l,length:u??36}));break;case"pointpropertytype":r="point",c=!0;break;case"multipointpropertytype":r="multipoint",c=!0;break;case"curvepropertytype":case"multicurvepropertytype":case"multilinestringpropertytype":r="polyline",c=!0;break;case"surfacepropertytype":case"multisurfacepropertytype":case"multipolygonpropertytype":r="polygon",c=!0;break;case"geometrypropertytype":case"multigeometrypropertytype":c=!0,t.push(new o.Z(E,`geometry type '${s}' is not supported`,{type:(new XMLSerializer).serializeToString(e)}));break;default:t.push(new o.Z(P,`Unknown field type '${s}'`,{type:(new XMLSerializer).serializeToString(e)}))}c&&n.push(new m.Z({name:i,alias:i,type:"geometry",nullable:l}))}for(const e of n)if("integer"===e.type&&!e.nullable&&I.has(e.name.toLowerCase())){e.type="oid";break}return{geometryType:r,fields:n,errors:t}}(e)}throw new o.Z(T,`Type '${e}' not found in document`,{document:(new XMLSerializer).serializeToString(r)})}(t,(await(0,r.default)(e,{responseType:"text",query:{SERVICE:"WFS",REQUEST:"DescribeFeatureType",VERSION:b,TYPENAME:t,...n?.customParameters},signal:n?.signal})).data)}const I=new Set(["objectid","fid"]);async function D(e,t,n,i){let{data:a}=await(0,r.default)(e,{responseType:"text",query:M(t,n,i),signal:i?.signal});a=a.replaceAll(/": +(-?\d+),(\d+)(,)?/g,'": $1.$2$3');try{if(i?.dateFields?.length){const e=new Set(i.dateFields);return JSON.parse(a,((t,n)=>e.has(t)?y(n):n))}return JSON.parse(a)}catch(e){throw new o.Z(x,"Error while parsing the response",{response:a,error:e})}}function M(e,t,n){return{SERVICE:"WFS",REQUEST:"GetFeature",VERSION:b,TYPENAMES:e,OUTPUTFORMAT:t,SRSNAME:"EPSG:4326",STARTINDEX:n?.startIndex,COUNT:n?.count,...n?.customParameters}}function U(e){return(new DOMParser).parseFromString(e.trim(),"text/xml")}function L(e){const[t,n]=e.split(":");return{prefix:n?t:"",name:n??t}}function J(e){let t="",n="";if((0,f.h)(e.firstElementChild,{Exception:e=>(t=e.getAttribute("exceptionCode"),{ExceptionText:e=>{n=e.textContent}})}),t)throw new o.Z(`wfs-layer:${t}`,n)}},88724:(e,t,n)=>{function r(e,t){if(e&&t)for(const n of e.children)if(n.localName in t){const e=t[n.localName];if("function"==typeof e){const t=e(n);t&&r(n,t)}else r(n,e)}}function*o(e,t){for(const n of e.children)if(n.localName in t){const e=t[n.localName];"function"==typeof e?yield e(n):yield*o(n,e)}}n.d(t,{H:()=>o,h:()=>r})},1231:(e,t,n)=>{n.d(t,{Z:()=>h});var r,o=n(43697),i=n(35454),a=n(96674),s=n(5600),u=n(75215),l=(n(67676),n(80442),n(36030)),c=n(71715),p=n(52011),y=n(72729),d=n(86719);const f=new i.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 m=r=class extends a.wq{constructor(e){super(e),this.alias=null,this.defaultValue=void 0,this.description=null,this.domain=null,this.editable=!0,this.length=-1,this.name=null,this.nullable=!0,this.type=null,this.valueType=null,this.visible=!0}readDescription(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?.value??null}readValueType(e,{description:t}){let n=null;try{n=t?JSON.parse(t):null}catch(e){}return n?f.fromJSON(n.fieldValueType):null}clone(){return new r({alias:this.alias,defaultValue:this.defaultValue,description:this.description,domain:this.domain&&this.domain.clone()||null,editable:this.editable,length:this.length,name:this.name,nullable:this.nullable,type:this.type,valueType:this.valueType,visible:this.visible})}};(0,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"alias",void 0),(0,o._)([(0,s.Cb)({type:[String,Number],json:{write:{allowNull:!0}}})],m.prototype,"defaultValue",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"description",void 0),(0,o._)([(0,c.r)("description")],m.prototype,"readDescription",null),(0,o._)([(0,s.Cb)({types:y.V5,json:{read:{reader:y.im},write:!0}})],m.prototype,"domain",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"editable",void 0),(0,o._)([(0,s.Cb)({type:u.z8,json:{write:!0}})],m.prototype,"length",void 0),(0,o._)([(0,s.Cb)({type:String,json:{write:!0}})],m.prototype,"name",void 0),(0,o._)([(0,s.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"nullable",void 0),(0,o._)([(0,l.J)(d.v)],m.prototype,"type",void 0),(0,o._)([(0,s.Cb)()],m.prototype,"valueType",void 0),(0,o._)([(0,c.r)("valueType",["description"])],m.prototype,"readValueType",null),(0,o._)([(0,s.Cb)({type:Boolean,json:{read:!1}})],m.prototype,"visible",void 0),m=r=(0,o._)([(0,p.j)("esri.layers.support.Field")],m);const h=m},72729:(e,t,n)=>{n.d(t,{im:()=>C,V5:()=>T}),n(80442);var r,o=n(43697),i=n(22974),a=n(5600),s=(n(75215),n(36030)),u=n(52011),l=n(96674);n(67676);let c=r=class extends l.wq{constructor(e){super(e),this.name=null,this.code=null}clone(){return new r({name:this.name,code:this.code})}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],c.prototype,"name",void 0),(0,o._)([(0,a.Cb)({type:[String,Number],json:{write:!0}})],c.prototype,"code",void 0),c=r=(0,o._)([(0,u.j)("esri.layers.support.CodedValue")],c);const p=new(n(35454).X)({inherited:"inherited",codedValue:"coded-value",range:"range"});let y=class extends l.wq{constructor(e){super(e),this.name=null,this.type=null}};(0,o._)([(0,a.Cb)({type:String,json:{write:!0}})],y.prototype,"name",void 0),(0,o._)([(0,s.J)(p)],y.prototype,"type",void 0),y=(0,o._)([(0,u.j)("esri.layers.support.Domain")],y);const d=y;var f;let m=f=class extends d{constructor(e){super(e),this.codedValues=null,this.type="coded-value"}getName(e){let t=null;if(this.codedValues){const n=String(e);this.codedValues.some((e=>(String(e.code)===n&&(t=e.name),!!t)))}return t}clone(){return new f({codedValues:(0,i.d9)(this.codedValues),name:this.name})}};(0,o._)([(0,a.Cb)({type:[c],json:{write:!0}})],m.prototype,"codedValues",void 0),(0,o._)([(0,s.J)({codedValue:"coded-value"})],m.prototype,"type",void 0),m=f=(0,o._)([(0,u.j)("esri.layers.support.CodedValueDomain")],m);const h=m;var g;n(92604),n(20102);let w=g=class extends d{constructor(e){super(e),this.type="inherited"}clone(){return new g}};(0,o._)([(0,s.J)({inherited:"inherited"})],w.prototype,"type",void 0),w=g=(0,o._)([(0,u.j)("esri.layers.support.InheritedDomain")],w);const b=w;var _;let S=_=class extends d{constructor(e){super(e),this.maxValue=null,this.minValue=null,this.type="range"}clone(){return new _({maxValue:this.maxValue,minValue:this.minValue,name:this.name})}};(0,o._)([(0,a.Cb)({type:Number,json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range&&t.range[1]},write:{enabled:!1,overridePolicy(){return{enabled:null!=this.maxValue&&null==this.minValue}},target:"range",writer(e,t,n){t[n]=[this.minValue||0,e]}}}})],S.prototype,"maxValue",void 0),(0,o._)([(0,a.Cb)({type:Number,json:{type:[Number],read:{source:"range",reader:(e,t)=>t.range&&t.range[0]},write:{target:"range",writer(e,t,n){t[n]=[e,this.maxValue||0]}}}})],S.prototype,"minValue",void 0),(0,o._)([(0,s.J)({range:"range"})],S.prototype,"type",void 0),S=_=(0,o._)([(0,u.j)("esri.layers.support.RangeDomain")],S);const F=S,T={key:"type",base:d,typeMap:{range:S,"coded-value":h,inherited:b}};function C(e){if(!e||!e.type)return null;switch(e.type){case"range":return F.fromJSON(e);case"codedValue":return h.fromJSON(e);case"inherited":return b.fromJSON(e)}return null}}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3172],{3172:(e,t,r)=>{r.r(t),r.d(t,{default:()=>f});var s=r(68773),o=r(40330),n=r(20102),a=r(80442),i=r(22974),l=r(95330),c=r(81271),u=r(19745),d=r(71058),h=r(85958);async function f(e,t){e instanceof URL&&(e=e.toString()),t?.query instanceof URLSearchParams&&(t.query=(0,c.u0)(t.query.toString().replaceAll("+"," ")));const i=(0,c.HK)(e),u=(0,c.jc)(e);u||i||(e=(0,c.Fv)(e));const w={url:e,requestOptions:{...t}};let g=(0,c.oh)(e);if(g){const e=await async function(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let r,s;try{s=await e.before(t)}catch(e){r=v("request:interceptor",e,t)}if((s instanceof Error||s instanceof n.Z)&&(r=v("request:interceptor",s,t)),r)throw e.error&&e.error(r),r;return s}}(g,w);if(null!=e)return{data:e,getHeader:q,httpStatus:200,requestOptions:w.requestOptions,url:w.url};g.after||g.error||(g=null)}if(e=w.url,"image"===(t=w.requestOptions).responseType&&((0,a.Z)("host-webworker")||(0,a.Z)("host-node")))throw v("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),w);if("head"===t.method){if(t.body)throw v("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),w);if(i||u)throw v("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),w)}if(await async function(){(0,a.Z)("host-webworker")?p||(p=await r.e(9884).then(r.bind(r,29884))):f._abortableFetch||(f._abortableFetch=globalThis.fetch.bind(globalThis))}(),p)return p.execute(e,t);const b=new AbortController;(0,l.fu)(t,(()=>b.abort()));const T={controller:b,credential:void 0,credentialToken:void 0,fetchOptions:void 0,hasToken:!1,interceptor:g,params:w,redoRequest:!1,useIdentity:m.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},k=await async function(e){let t,r;await async function(e){const t=e.params.url,r=e.params.requestOptions,n=e.controller.signal,a=r.body;let i=null,c=null;if(y&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(i=new FormData(a))),"string"==typeof a&&(c=a),e.fetchOptions={cache:r.cacheBust&&!("polyfill"in f._abortableFetch)?"no-cache":"default",credentials:"same-origin",headers:r.headers||{},method:"head"===r.method?"HEAD":"GET",mode:"cors",priority:m.priority,redirect:"follow",signal:n},(i||c)&&(e.fetchOptions.body=i||c),"anonymous"===r.authMode&&(e.useIdentity=!1),e.hasToken=!!(/token=/i.test(t)||r.query?.token||i?.get("token")),!e.hasToken&&s.default.apiKey&&(0,d.r)(t)&&(r.query||(r.query={}),r.query.token=s.default.apiKey,e.hasToken=!0),e.useIdentity&&!e.hasToken&&!e.credentialToken&&!C(t)&&!(0,l.Hc)(n)){let s;"immediate"===r.authMode?(await O(),s=await o.id.getCredential(t,{signal:n}),e.credential=s):"no-prompt"===r.authMode?(await O(),s=await o.id.getCredential(t,{prompt:!1,signal:n}).catch((()=>{})),e.credential=s):o.id&&(s=o.id.findCredential(t)),s&&(e.credentialToken=s.token,e.useSSL=!!s.ssl)}}(e);try{do{[t,r]=await S(e)}while(!await L(e,t,r))}catch(r){const s=v("request:server",r,e.params,t);throw s.details.ssl=e.useSSL,e.interceptor?.error&&e.interceptor.error(s),s}const n=e.params.url;if(r&&/\/sharing\/rest\/(accounts|portals)\/self/i.test(n)){if(!e.hasToken&&!e.credentialToken&&r.user?.username&&!(0,c.kl)(n)){const e=(0,c.P$)(n,!0);e&&m.trustedServers.push(e)}Array.isArray(r.authorizedCrossOriginNoCorsDomains)&&(0,h.Hu)(r.authorizedCrossOriginNoCorsDomains)}const a=e.credential;if(a&&o.id){const e=o.id.findServerInfo(a.server);let t=e?.owningSystemUrl;if(t){t=t.replace(/\/?$/,"/sharing");const e=o.id.findCredential(t,a.userId);e&&-1===o.id._getIdenticalSvcIdx(t,e)&&e.resources.unshift(t)}}return{data:r,getHeader:t?e=>t?.headers.get(e):q,httpStatus:t?.status??200,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}(T);return g?.after?.(k),k}let p;const m=s.default.request,y="FormData"in globalThis,w=[499,498,403,401],g=["COM_0056","COM_0057","SB_0008"],b=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],q=()=>null,T=Symbol();function k(e){const t=(0,c.P$)(e);return!t||t.endsWith(".arcgis.com")||f._corsServers.includes(t)||(0,c.kl)(t)}function v(e,t,r,s){let o="Error";const a={url:r.url,requestOptions:r.requestOptions,getHeader:q,ssl:!1};if(t instanceof n.Z)return t.details?(t.details=(0,i.d9)(t.details),t.details.url=r.url,t.details.requestOptions=r.requestOptions):t.details=a,t;if(t){const e=s&&(e=>s.headers.get(e)),r=s?.status,n=t.message;n&&(o=n),e&&(a.getHeader=e),a.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,a.subCode=t.subcode,a.messageCode=t.messageCode,"string"==typeof t.details?a.messages=[t.details]:a.messages=t.details,a.raw=T in t?t[T]:t}return(0,l.D_)(t)?(0,l.zE)():new n.Z(e,o,a)}async function O(){o.id||await Promise.all([r.e(7126),r.e(6261),r.e(9255),r.e(1400),r.e(450)]).then(r.bind(r,73660))}function C(e){return b.some((t=>t.test(e)))}async function S(e){let t=e.params.url;const r=e.params.requestOptions,s=e.fetchOptions??{},n=(0,c.jc)(t)||(0,c.HK)(t),i=r.responseType||"json",d=n?0:null!=r.timeout?r.timeout:m.timeout;let p=!1;if(!n){e.useSSL&&(t=(0,c.hO)(t)),r.cacheBust&&"default"===s.cache&&(t=(0,c.ZN)(t,"request.preventCache",Date.now()));let n={...r.query};e.credentialToken&&(n.token=e.credentialToken);let i=(0,c.B7)(n);(0,a.Z)("esri-url-encodes-apostrophe")&&(i=i.replaceAll("'","%27"));const l=t.length+1+i.length;let d;p="delete"===r.method||"post"===r.method||"put"===r.method||!!r.body||l>m.maxUrlLength;const f=r.useProxy||!!(0,c.ed)(t);if(f){const e=(0,c.b7)(t);d=e.path,!p&&d.length+1+l>m.maxUrlLength&&(p=!0),e.query&&(n={...e.query,...n})}if("HEAD"===s.method&&(p||f)){if(p){if(l>m.maxUrlLength)throw v("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw v("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(f)throw v("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(p?(s.method="delete"===r.method?"DELETE":"put"===r.method?"PUT":"POST",r.body?t=(0,c.fl)(t,n):(s.body=(0,c.B7)(n),s.headers||(s.headers={}),s.headers["Content-Type"]="application/x-www-form-urlencoded")):t=(0,c.fl)(t,n),f&&(e.useProxy=!0,t=`${d}?${t}`),n.token&&y&&s.body instanceof FormData&&!(0,u.P)(t)&&s.body.set("token",n.token),r.hasOwnProperty("withCredentials"))e.withCredentials=r.withCredentials;else if(!(0,c.D6)(t,(0,c.TI)()))if((0,c.kl)(t))e.withCredentials=!0;else if(o.id){const r=o.id.findServerInfo(t);r?.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(s.credentials="include",(0,h.jH)(t)&&await(0,h.jz)(p?(0,c.fl)(t,n):t))}let w,g,b=0,q=!1;d>0&&(b=setTimeout((()=>{q=!0,e.controller.abort()}),d));try{if("native-request-init"===r.responseType)g=s,g.url=t;else if("image"!==r.responseType||"default"!==s.cache||"GET"!==s.method||p||function(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}(r.headers)||!n&&!e.useProxy&&m.proxyUrl&&!k(t)){if(w=await f._abortableFetch(t,s),e.useProxy||function(e){const t=(0,c.P$)(e);t&&!f._corsServers.includes(t)&&f._corsServers.push(t)}(t),"native"===r.responseType)g=w;else if("HEAD"!==s.method)if(w.ok){switch(i){case"array-buffer":g=await w.arrayBuffer();break;case"blob":case"image":g=await w.blob();break;default:g=await w.text()}if(b&&(clearTimeout(b),b=0),"json"===i||"xml"===i||"document"===i)if(g)switch(i){case"json":g=JSON.parse(g);break;case"xml":g=E(g,"application/xml");break;case"document":g=E(g,"text/html")}else g=null;if(g){if("array-buffer"===i||"blob"===i){const e=w.headers.get("Content-Type");if(e&&/application\/json|text\/plain/i.test(e)&&g["blob"===i?"size":"byteLength"]<=750)try{const e=await new Response(g).json();e.error&&(g=e)}catch{}}"image"===i&&g instanceof Blob&&(g=await x(URL.createObjectURL(g),e,!0))}}else{g=await w.text();try{g=JSON.parse(g)}catch{}}}else g=await x(t,e)}catch(s){if("AbortError"===s.name){if(q)throw new Error("Timeout exceeded");throw(0,l.zE)("Request canceled")}if(!(!w&&s instanceof TypeError&&m.proxyUrl)||r.body||"delete"===r.method||"head"===r.method||"post"===r.method||"put"===r.method||e.useProxy||k(t))throw s;e.redoRequest=!0,(0,c.tD)({proxyUrl:m.proxyUrl,urlPrefix:(0,c.P$)(t)??""})}finally{b&&clearTimeout(b)}return[w,g]}function E(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function L(e,t,r){if(e.redoRequest)return e.redoRequest=!1,!1;const s=e.params.requestOptions;if(!t||"native"===s.responseType||"native-request-init"===s.responseType)return!0;let n,a;if(r&&(r.error?n=r.error:"error"===r.status&&Array.isArray(r.messages)&&(n={...r},n[T]=r,n.details=r.messages)),!n&&!t.ok)throw n=new Error(`Unable to load ${t.url} status: ${t.status}`),n[T]=r,n;let i,l=null;n&&(a=Number(n.code),l=n.hasOwnProperty("subcode")?Number(n.subcode):null,i=n.messageCode,i=i?.toUpperCase());const c=s.authMode;if(403===a&&(4===l||n.message?.toLowerCase().includes("ssl")&&!n.message.toLowerCase().includes("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==c||498===a)&&void 0!==a&&w.includes(a)&&!C(e.params.url)&&(403!==a||i&&!g.includes(i)&&(null==l||2===l&&e.credentialToken))){await O();try{const t=await o.id.getCredential(e.params.url,{error:v("request:server",n,e.params),prompt:"no-prompt"!==c,signal:e.controller.signal,token:e.credentialToken});return e.credential=t,e.credentialToken=t.token,e.useSSL=e.useSSL||t.ssl,!1}catch(t){if("no-prompt"===c)return e.credential=void 0,e.credentialToken=void 0,!1;n=t}}if(n)throw n;return!0}function x(e,t,r=!1){const s=t.controller.signal,o=new Image;return t.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchPriority=m.priority,o.src=e,(0,h.fY)(o,e,r,s)}f._abortableFetch=null,f._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"]},71058:(e,t,r)=>{r.d(t,{r:()=>n});var s=r(81271);const o=["elevation3d.arcgis.com","js.arcgis.com","jsdev.arcgis.com","jsqa.arcgis.com","static.arcgis.com"];function n(e){const t=(0,s.P$)(e,!0);return!!t&&t.endsWith(".arcgis.com")&&!o.includes(t)&&!e.endsWith("/sharing/rest/generateToken")}},85958:(e,t,r)=>{r.d(t,{Hu:()=>c,fY:()=>i,jH:()=>u,jz:()=>d});var s=r(68773),o=r(80442),n=r(95330),a=r(81271);function i(e,t,r=!1,s){return new Promise(((a,i)=>{if((0,n.Hc)(s))return void i(l());let c=()=>{h(),i(new Error(`Unable to load ${t}`))},u=()=>{const t=e;h(),a(t)},d=()=>{if(!e)return;const t=e;h(),t.src="",i(l())};const h=()=>{(0,o.Z)("esri-image-decode")||(e.removeEventListener("error",c),e.removeEventListener("load",u)),c=null,u=null,e=null,null!=s&&s.removeEventListener("abort",d),d=null,r&&URL.revokeObjectURL(t)};null!=s&&s.addEventListener("abort",d),(0,o.Z)("esri-image-decode")?e.decode().then(u,c):(e.addEventListener("error",c),e.addEventListener("load",u))}))}function l(){try{return new DOMException("Aborted","AbortError")}catch{const e=new Error;return e.name="AbortError",e}}function c(e){s.default.request.crossOriginNoCorsDomains||(s.default.request.crossOriginNoCorsDomains={});const t=s.default.request.crossOriginNoCorsDomains;for(let r of e)r=r.toLowerCase(),/^https?:\/\//.test(r)?t[(0,a.P$)(r)??""]=0:(t[(0,a.P$)("http://"+r)??""]=0,t[(0,a.P$)("https://"+r)??""]=0)}function u(e){const t=s.default.request.crossOriginNoCorsDomains;if(t){let r=(0,a.P$)(e);if(r)return r=r.toLowerCase(),!(0,a.D6)(r,(0,a.TI)())&&t[r]<Date.now()-36e5}return!1}async function d(e){const t=s.default.request.crossOriginNoCorsDomains,r=(0,a.P$)(e);t&&r&&(t[r.toLowerCase()]=Date.now());const o=(0,a.mN)(e);e=o.path,"json"===o.query?.f&&(e+="?f=json");try{await fetch(e,{mode:"no-cors",credentials:"include"})}catch{}}}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3172],{3172:(e,t,r)=>{r.r(t),r.d(t,{default:()=>f});var s=r(68773),o=r(40330),n=r(20102),a=r(80442),i=r(22974),l=r(95330),c=r(81271),u=r(19745),d=r(71058),h=r(85958);async function f(e,t){e instanceof URL&&(e=e.toString()),t?.query instanceof URLSearchParams&&(t.query=(0,c.u0)(t.query.toString().replaceAll("+"," ")));const i=(0,c.HK)(e),u=(0,c.jc)(e);u||i||(e=(0,c.Fv)(e));const w={url:e,requestOptions:{...t}};let g=(0,c.oh)(e);if(g){const e=await async function(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let r,s;try{s=await e.before(t)}catch(e){r=v("request:interceptor",e,t)}if((s instanceof Error||s instanceof n.Z)&&(r=v("request:interceptor",s,t)),r)throw e.error&&e.error(r),r;return s}}(g,w);if(null!=e)return{data:e,getHeader:q,httpStatus:200,requestOptions:w.requestOptions,url:w.url};g.after||g.error||(g=null)}if(e=w.url,"image"===(t=w.requestOptions).responseType&&((0,a.Z)("host-webworker")||(0,a.Z)("host-node")))throw v("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),w);if("head"===t.method){if(t.body)throw v("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),w);if(i||u)throw v("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),w)}if(await async function(){(0,a.Z)("host-webworker")?p||(p=await r.e(9884).then(r.bind(r,29884))):f._abortableFetch||(f._abortableFetch=globalThis.fetch.bind(globalThis))}(),p)return p.execute(e,t);const b=new AbortController;(0,l.fu)(t,(()=>b.abort()));const T={controller:b,credential:void 0,credentialToken:void 0,fetchOptions:void 0,hasToken:!1,interceptor:g,params:w,redoRequest:!1,useIdentity:m.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},k=await async function(e){let t,r;await async function(e){const t=e.params.url,r=e.params.requestOptions,n=e.controller.signal,a=r.body;let i=null,c=null;if(y&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(i=new FormData(a))),"string"==typeof a&&(c=a),e.fetchOptions={cache:r.cacheBust&&!("polyfill"in f._abortableFetch)?"no-cache":"default",credentials:"same-origin",headers:r.headers||{},method:"head"===r.method?"HEAD":"GET",mode:"cors",priority:m.priority,redirect:"follow",signal:n},(i||c)&&(e.fetchOptions.body=i||c),"anonymous"===r.authMode&&(e.useIdentity=!1),e.hasToken=!!(/token=/i.test(t)||r.query?.token||i?.get("token")),!e.hasToken&&s.default.apiKey&&(0,d.r)(t)&&(r.query||(r.query={}),r.query.token=s.default.apiKey,e.hasToken=!0),e.useIdentity&&!e.hasToken&&!e.credentialToken&&!C(t)&&!(0,l.Hc)(n)){let s;"immediate"===r.authMode?(await O(),s=await o.id.getCredential(t,{signal:n}),e.credential=s):"no-prompt"===r.authMode?(await O(),s=await o.id.getCredential(t,{prompt:!1,signal:n}).catch((()=>{})),e.credential=s):o.id&&(s=o.id.findCredential(t)),s&&(e.credentialToken=s.token,e.useSSL=!!s.ssl)}}(e);try{do{[t,r]=await S(e)}while(!await L(e,t,r))}catch(r){const s=v("request:server",r,e.params,t);throw s.details.ssl=e.useSSL,e.interceptor?.error&&e.interceptor.error(s),s}const n=e.params.url;if(r&&/\/sharing\/rest\/(accounts|portals)\/self/i.test(n)){if(!e.hasToken&&!e.credentialToken&&r.user?.username&&!(0,c.kl)(n)){const e=(0,c.P$)(n,!0);e&&m.trustedServers.push(e)}Array.isArray(r.authorizedCrossOriginNoCorsDomains)&&(0,h.Hu)(r.authorizedCrossOriginNoCorsDomains)}const a=e.credential;if(a&&o.id){const e=o.id.findServerInfo(a.server);let t=e?.owningSystemUrl;if(t){t=t.replace(/\/?$/,"/sharing");const e=o.id.findCredential(t,a.userId);e&&-1===o.id._getIdenticalSvcIdx(t,e)&&e.resources.unshift(t)}}return{data:r,getHeader:t?e=>t?.headers.get(e):q,httpStatus:t?.status??200,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}(T);return g?.after?.(k),k}let p;const m=s.default.request,y="FormData"in globalThis,w=[499,498,403,401],g=["COM_0056","COM_0057","SB_0008"],b=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],q=()=>null,T=Symbol();function k(e){const t=(0,c.P$)(e);return!t||t.endsWith(".arcgis.com")||f._corsServers.includes(t)||(0,c.kl)(t)}function v(e,t,r,s){let o="Error";const a={url:r.url,requestOptions:r.requestOptions,getHeader:q,ssl:!1};if(t instanceof n.Z)return t.details?(t.details=(0,i.d9)(t.details),t.details.url=r.url,t.details.requestOptions=r.requestOptions):t.details=a,t;if(t){const e=s&&(e=>s.headers.get(e)),r=s?.status,n=t.message;n&&(o=n),e&&(a.getHeader=e),a.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,a.subCode=t.subcode,a.messageCode=t.messageCode,"string"==typeof t.details?a.messages=[t.details]:a.messages=t.details,a.raw=T in t?t[T]:t}return(0,l.D_)(t)?(0,l.zE)():new n.Z(e,o,a)}async function O(){o.id||await Promise.all([r.e(7126),r.e(6261),r.e(9255),r.e(1400),r.e(450)]).then(r.bind(r,73660))}function C(e){return b.some((t=>t.test(e)))}async function S(e){let t=e.params.url;const r=e.params.requestOptions,s=e.fetchOptions??{},n=(0,c.jc)(t)||(0,c.HK)(t),i=r.responseType||"json",d=n?0:null!=r.timeout?r.timeout:m.timeout;let p=!1;if(!n){e.useSSL&&(t=(0,c.hO)(t)),r.cacheBust&&"default"===s.cache&&(t=(0,c.ZN)(t,"request.preventCache",Date.now()));let n={...r.query};e.credentialToken&&(n.token=e.credentialToken);let i=(0,c.B7)(n);(0,a.Z)("esri-url-encodes-apostrophe")&&(i=i.replaceAll("'","%27"));const l=t.length+1+i.length;let d;p="delete"===r.method||"post"===r.method||"put"===r.method||!!r.body||l>m.maxUrlLength;const f=r.useProxy||!!(0,c.ed)(t);if(f){const e=(0,c.b7)(t);d=e.path,!p&&d.length+1+l>m.maxUrlLength&&(p=!0),e.query&&(n={...e.query,...n})}if("HEAD"===s.method&&(p||f)){if(p){if(l>m.maxUrlLength)throw v("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw v("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(f)throw v("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(p?(s.method="delete"===r.method?"DELETE":"put"===r.method?"PUT":"POST",r.body?t=(0,c.fl)(t,n):(s.body=(0,c.B7)(n),s.headers||(s.headers={}),s.headers["Content-Type"]="application/x-www-form-urlencoded")):t=(0,c.fl)(t,n),f&&(e.useProxy=!0,t=`${d}?${t}`),n.token&&y&&s.body instanceof FormData&&!(0,u.P)(t)&&s.body.set("token",n.token),r.hasOwnProperty("withCredentials"))e.withCredentials=r.withCredentials;else if(!(0,c.D6)(t,(0,c.TI)()))if((0,c.kl)(t))e.withCredentials=!0;else if(o.id){const r=o.id.findServerInfo(t);r?.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(s.credentials="include",(0,h.jH)(t)&&await(0,h.jz)(p?(0,c.fl)(t,n):t))}let w,g,b=0,q=!1;d>0&&(b=setTimeout((()=>{q=!0,e.controller.abort()}),d));try{if("native-request-init"===r.responseType)g=s,g.url=t;else if("image"!==r.responseType||"default"!==s.cache||"GET"!==s.method||p||function(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}(r.headers)||!n&&!e.useProxy&&m.proxyUrl&&!k(t)){if(w=await f._abortableFetch(t,s),e.useProxy||function(e){const t=(0,c.P$)(e);t&&!f._corsServers.includes(t)&&f._corsServers.push(t)}(t),"native"===r.responseType)g=w;else if("HEAD"!==s.method)if(w.ok){switch(i){case"array-buffer":g=await w.arrayBuffer();break;case"blob":case"image":g=await w.blob();break;default:g=await w.text()}if(b&&(clearTimeout(b),b=0),"json"===i||"xml"===i||"document"===i)if(g)switch(i){case"json":g=JSON.parse(g);break;case"xml":g=E(g,"application/xml");break;case"document":g=E(g,"text/html")}else g=null;if(g){if("array-buffer"===i||"blob"===i){const e=w.headers.get("Content-Type");if(e&&/application\/json|text\/plain/i.test(e)&&g["blob"===i?"size":"byteLength"]<=750)try{const e=await new Response(g).json();e.error&&(g=e)}catch{}}"image"===i&&g instanceof Blob&&(g=await x(URL.createObjectURL(g),e,!0))}}else{g=await w.text();try{g=JSON.parse(g)}catch{}}}else g=await x(t,e)}catch(s){if("AbortError"===s.name){if(q)throw(0,h.Tf)();throw(0,l.zE)("Request canceled")}if(!(!w&&s instanceof TypeError&&m.proxyUrl)||r.body||"delete"===r.method||"head"===r.method||"post"===r.method||"put"===r.method||e.useProxy||k(t))throw s;e.redoRequest=!0,(0,c.tD)({proxyUrl:m.proxyUrl,urlPrefix:(0,c.P$)(t)??""})}finally{b&&clearTimeout(b)}return[w,g]}function E(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function L(e,t,r){if(e.redoRequest)return e.redoRequest=!1,!1;const s=e.params.requestOptions;if(!t||"native"===s.responseType||"native-request-init"===s.responseType)return!0;let n,a;if(r&&(r.error?n=r.error:"error"===r.status&&Array.isArray(r.messages)&&(n={...r},n[T]=r,n.details=r.messages)),!n&&!t.ok)throw n=new Error(`Unable to load ${t.url} status: ${t.status}`),n[T]=r,n;let i,l=null;n&&(a=Number(n.code),l=n.hasOwnProperty("subcode")?Number(n.subcode):null,i=n.messageCode,i=i?.toUpperCase());const c=s.authMode;if(403===a&&(4===l||n.message?.toLowerCase().includes("ssl")&&!n.message.toLowerCase().includes("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==c||498===a)&&void 0!==a&&w.includes(a)&&!C(e.params.url)&&(403!==a||i&&!g.includes(i)&&(null==l||2===l&&e.credentialToken))){await O();try{const t=await o.id.getCredential(e.params.url,{error:v("request:server",n,e.params),prompt:"no-prompt"!==c,signal:e.controller.signal,token:e.credentialToken});return e.credential=t,e.credentialToken=t.token,e.useSSL=e.useSSL||t.ssl,!1}catch(t){if("no-prompt"===c)return e.credential=void 0,e.credentialToken=void 0,!1;n=t}}if(n)throw n;return!0}function x(e,t,r=!1){const s=t.controller.signal,o=new Image;return t.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchPriority=m.priority,o.src=e,(0,h.fY)(o,e,r,s)}f._abortableFetch=null,f._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"]},71058:(e,t,r)=>{r.d(t,{r:()=>n});var s=r(81271);const o=["elevation3d.arcgis.com","js.arcgis.com","jsdev.arcgis.com","jsqa.arcgis.com","static.arcgis.com"];function n(e){const t=(0,s.P$)(e,!0);return!!t&&t.endsWith(".arcgis.com")&&!o.includes(t)&&!e.endsWith("/sharing/rest/generateToken")}},85958:(e,t,r)=>{r.d(t,{Hu:()=>d,Tf:()=>u,fY:()=>i,jH:()=>h,jz:()=>f});var s=r(68773),o=r(80442),n=r(95330),a=r(81271);function i(e,t,r=!1,s){return new Promise(((a,i)=>{if((0,n.Hc)(s))return void i(l());let c=()=>{h(),i(new Error(`Unable to load ${t}`))},u=()=>{const t=e;h(),a(t)},d=()=>{if(!e)return;const t=e;h(),t.src="",i(l())};const h=()=>{(0,o.Z)("esri-image-decode")||(e.removeEventListener("error",c),e.removeEventListener("load",u)),c=null,u=null,e=null,null!=s&&s.removeEventListener("abort",d),d=null,r&&URL.revokeObjectURL(t)};null!=s&&s.addEventListener("abort",d),(0,o.Z)("esri-image-decode")?e.decode().then(u,c):(e.addEventListener("error",c),e.addEventListener("load",u))}))}function l(){try{return new DOMException("Aborted","AbortError")}catch{const e=new Error;return e.name="AbortError",e}}const c="Timeout exceeded";function u(){return new Error(c)}function d(e){s.default.request.crossOriginNoCorsDomains||(s.default.request.crossOriginNoCorsDomains={});const t=s.default.request.crossOriginNoCorsDomains;for(let r of e)r=r.toLowerCase(),/^https?:\/\//.test(r)?t[(0,a.P$)(r)??""]=0:(t[(0,a.P$)("http://"+r)??""]=0,t[(0,a.P$)("https://"+r)??""]=0)}function h(e){const t=s.default.request.crossOriginNoCorsDomains;if(t){let r=(0,a.P$)(e);if(r)return r=r.toLowerCase(),!(0,a.D6)(r,(0,a.TI)())&&t[r]<Date.now()-36e5}return!1}async function f(e){const t=s.default.request.crossOriginNoCorsDomains,r=(0,a.P$)(e);t&&r&&(t[r.toLowerCase()]=Date.now());const o=(0,a.mN)(e);e=o.path,"json"===o.query?.f&&(e+="?f=json");try{await fetch(e,{mode:"no-cors",credentials:"include"})}catch{}}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[7872,3172,5732,661,5234,9880],{22303:(e,t,r)=>{r.d(t,{Z:()=>h});var n,o,s=r(35270),a=r(22021),i=r(75215);function l(e){return(0,a.uZ)((0,i.vU)(e),0,255)}function u(e,t,r){return e=Number(e),isNaN(e)?r:e<t?t:e>r?r:e}class c{static blendColors(e,t,r,n=new c){return n.r=Math.round(e.r+(t.r-e.r)*r),n.g=Math.round(e.g+(t.g-e.g)*r),n.b=Math.round(e.b+(t.b-e.b)*r),n.a=e.a+(t.a-e.a)*r,n._sanitize()}static fromRgb(e,t){const r=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s\.\-,%0-9]+)\)/);if(r){const e=r[2].split(/\s*,\s*/),n=r[1];if("rgb"===n&&3===e.length||"rgba"===n&&4===e.length){const r=e[0];if("%"===r.charAt(r.length-1)){const r=e.map((e=>2.56*parseFloat(e)));return 4===e.length&&(r[3]=parseFloat(e[3])),c.fromArray(r,t)}return c.fromArray(e.map((e=>parseFloat(e))),t)}if("hsl"===n&&3===e.length||"hsla"===n&&4===e.length)return c.fromArray((0,s.B7)(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3])),t)}return null}static fromHex(e,t=new c){if(4!==e.length&&7!==e.length||"#"!==e[0])return null;const r=4===e.length?4:8,n=(1<<r)-1;let o=Number("0x"+e.substr(1));return isNaN(o)?null:(["b","g","r"].forEach((e=>{const s=o&n;o>>=r,t[e]=4===r?17*s:s})),t.a=1,t)}static fromArray(e,t=new c){return t._set(Number(e[0]),Number(e[1]),Number(e[2]),Number(e[3])),isNaN(t.a)&&(t.a=1),t._sanitize()}static fromString(e,t){const r=(0,s.St)(e)?(0,s.h$)(e):null;return r&&c.fromArray(r,t)||c.fromRgb(e,t)||c.fromHex(e,t)}static fromJSON(e){return e&&new c([e[0],e[1],e[2],e[3]/255])}static toUnitRGB(e){return null!=e?[e.r/255,e.g/255,e.b/255]:null}static toUnitRGBA(e){return null!=e?[e.r/255,e.g/255,e.b/255,null!=e.a?e.a:1]:null}constructor(e){this.r=255,this.g=255,this.b=255,this.a=1,e&&this.setColor(e)}get isBright(){return.299*this.r+.587*this.g+.114*this.b>=127}setColor(e){return"string"==typeof e?c.fromString(e,this):Array.isArray(e)?c.fromArray(e,this):(this._set(e.r??0,e.g??0,e.b??0,e.a??1),e instanceof c||this._sanitize()),this}toRgb(){return[this.r,this.g,this.b]}toRgba(){return[this.r,this.g,this.b,this.a]}toHex(){const e=this.r.toString(16),t=this.g.toString(16),r=this.b.toString(16);return`#${e.length<2?"0"+e:e}${t.length<2?"0"+t:t}${r.length<2?"0"+r:r}`}toCss(e=!1){const t=this.r+", "+this.g+", "+this.b;return e?`rgba(${t}, ${this.a})`:`rgb(${t})`}toString(){return this.toCss(!0)}toJSON(){return this.toArray()}toArray(e=c.AlphaMode.ALWAYS){const t=l(this.r),r=l(this.g),n=l(this.b);return e===c.AlphaMode.ALWAYS||1!==this.a?[t,r,n,l(255*this.a)]:[t,r,n]}clone(){return new c(this.toRgba())}hash(){return this.r<<24|this.g<<16|this.b<<8|255*this.a}equals(e){return null!=e&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a}_sanitize(){return this.r=Math.round(u(this.r,0,255)),this.g=Math.round(u(this.g,0,255)),this.b=Math.round(u(this.b,0,255)),this.a=u(this.a,0,1),this}_set(e,t,r,n){this.r=e,this.g=t,this.b=r,this.a=n}}c.prototype.declaredClass="esri.Color",n=c||(c={}),(o=n.AlphaMode||(n.AlphaMode={}))[o.ALWAYS=0]="ALWAYS",o[o.UNLESS_OPAQUE=1]="UNLESS_OPAQUE";const h=c},99880:(e,t,r)=>{r.d(t,{V:()=>l});var n=r(68773),o=(r(3172),r(20102)),s=r(92604),a=r(81271);const i=s.Z.getLogger("esri.assets");function l(e){if(!n.default.assetsPath)throw i.errorOnce("The API assets location needs to be set using config.assetsPath. More information: https://arcg.is/1OzLe50"),new o.Z("assets:path-not-set","config.assetsPath is not set");return(0,a.v_)(n.default.assetsPath,e)}},5732:(e,t,r)=>{r.d(t,{c:()=>n,g:()=>o});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function o(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}},52138:(e,t,r)=>{r.d(t,{A:()=>p,a:()=>l,d:()=>f,e:()=>d,f:()=>m,g:()=>b,h:()=>M,i:()=>a,j:()=>v,k:()=>h,m:()=>u,s:()=>s,t:()=>i,w:()=>c,y:()=>k,z:()=>S});var n=r(65617),o=r(46851);function s(e,t,r,n,o,s,a,i,l,u,c,h,d,m,f,p,g){return e[0]=t,e[1]=r,e[2]=n,e[3]=o,e[4]=s,e[5]=a,e[6]=i,e[7]=l,e[8]=u,e[9]=c,e[10]=h,e[11]=d,e[12]=m,e[13]=f,e[14]=p,e[15]=g,e}function a(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function i(e,t){if(e===t){const r=t[1],n=t[2],o=t[3],s=t[6],a=t[7],i=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=r,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=s,e[11]=t[14],e[12]=o,e[13]=a,e[14]=i}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function l(e,t){const r=t[0],n=t[1],o=t[2],s=t[3],a=t[4],i=t[5],l=t[6],u=t[7],c=t[8],h=t[9],d=t[10],m=t[11],f=t[12],p=t[13],g=t[14],y=t[15],b=r*i-n*a,w=r*l-o*a,M=r*u-s*a,v=n*l-o*i,S=n*u-s*i,k=o*u-s*l,O=c*p-h*f,x=c*g-d*f,q=c*y-m*f,C=h*g-d*p,P=h*y-m*p,N=d*y-m*g;let T=b*N-w*P+M*C+v*q-S*x+k*O;return T?(T=1/T,e[0]=(i*N-l*P+u*C)*T,e[1]=(o*P-n*N-s*C)*T,e[2]=(p*k-g*S+y*v)*T,e[3]=(d*S-h*k-m*v)*T,e[4]=(l*q-a*N-u*x)*T,e[5]=(r*N-o*q+s*x)*T,e[6]=(g*M-f*k-y*w)*T,e[7]=(c*k-d*M+m*w)*T,e[8]=(a*P-i*q+u*O)*T,e[9]=(n*q-r*P-s*O)*T,e[10]=(f*S-p*M+y*b)*T,e[11]=(h*M-c*S-m*b)*T,e[12]=(i*x-a*C-l*O)*T,e[13]=(r*C-n*x+o*O)*T,e[14]=(p*w-f*v-g*b)*T,e[15]=(c*v-h*w+d*b)*T,e):null}function u(e,t,r){const n=t[0],o=t[1],s=t[2],a=t[3],i=t[4],l=t[5],u=t[6],c=t[7],h=t[8],d=t[9],m=t[10],f=t[11],p=t[12],g=t[13],y=t[14],b=t[15];let w=r[0],M=r[1],v=r[2],S=r[3];return e[0]=w*n+M*i+v*h+S*p,e[1]=w*o+M*l+v*d+S*g,e[2]=w*s+M*u+v*m+S*y,e[3]=w*a+M*c+v*f+S*b,w=r[4],M=r[5],v=r[6],S=r[7],e[4]=w*n+M*i+v*h+S*p,e[5]=w*o+M*l+v*d+S*g,e[6]=w*s+M*u+v*m+S*y,e[7]=w*a+M*c+v*f+S*b,w=r[8],M=r[9],v=r[10],S=r[11],e[8]=w*n+M*i+v*h+S*p,e[9]=w*o+M*l+v*d+S*g,e[10]=w*s+M*u+v*m+S*y,e[11]=w*a+M*c+v*f+S*b,w=r[12],M=r[13],v=r[14],S=r[15],e[12]=w*n+M*i+v*h+S*p,e[13]=w*o+M*l+v*d+S*g,e[14]=w*s+M*u+v*m+S*y,e[15]=w*a+M*c+v*f+S*b,e}function c(e,t,r){const n=r[0],o=r[1],s=r[2];if(t===e)e[12]=t[0]*n+t[4]*o+t[8]*s+t[12],e[13]=t[1]*n+t[5]*o+t[9]*s+t[13],e[14]=t[2]*n+t[6]*o+t[10]*s+t[14],e[15]=t[3]*n+t[7]*o+t[11]*s+t[15];else{const r=t[0],a=t[1],i=t[2],l=t[3],u=t[4],c=t[5],h=t[6],d=t[7],m=t[8],f=t[9],p=t[10],g=t[11];e[0]=r,e[1]=a,e[2]=i,e[3]=l,e[4]=u,e[5]=c,e[6]=h,e[7]=d,e[8]=m,e[9]=f,e[10]=p,e[11]=g,e[12]=r*n+u*o+m*s+t[12],e[13]=a*n+c*o+f*s+t[13],e[14]=i*n+h*o+p*s+t[14],e[15]=l*n+d*o+g*s+t[15]}return e}function h(e,t,r){const n=r[0],o=r[1],s=r[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*o,e[5]=t[5]*o,e[6]=t[6]*o,e[7]=t[7]*o,e[8]=t[8]*s,e[9]=t[9]*s,e[10]=t[10]*s,e[11]=t[11]*s,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function d(e,t,r,n){let s,a,i,l,u,c,h,d,m,f,p,g,y,b,w,M,v,S,k,O,x,q,C,P,N=n[0],T=n[1],Z=n[2],A=Math.sqrt(N*N+T*T+Z*Z);return A<(0,o.g)()?null:(A=1/A,N*=A,T*=A,Z*=A,s=Math.sin(r),a=Math.cos(r),i=1-a,l=t[0],u=t[1],c=t[2],h=t[3],d=t[4],m=t[5],f=t[6],p=t[7],g=t[8],y=t[9],b=t[10],w=t[11],M=N*N*i+a,v=T*N*i+Z*s,S=Z*N*i-T*s,k=N*T*i-Z*s,O=T*T*i+a,x=Z*T*i+N*s,q=N*Z*i+T*s,C=T*Z*i-N*s,P=Z*Z*i+a,e[0]=l*M+d*v+g*S,e[1]=u*M+m*v+y*S,e[2]=c*M+f*v+b*S,e[3]=h*M+p*v+w*S,e[4]=l*k+d*O+g*x,e[5]=u*k+m*O+y*x,e[6]=c*k+f*O+b*x,e[7]=h*k+p*O+w*x,e[8]=l*q+d*C+g*P,e[9]=u*q+m*C+y*P,e[10]=c*q+f*C+b*P,e[11]=h*q+p*C+w*P,t!==e&&(e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e)}function m(e,t){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=t[0],e[13]=t[1],e[14]=t[2],e[15]=1,e}function f(e,t,r){if(0===t)return a(e);let n,s,i,l=r[0],u=r[1],c=r[2],h=Math.sqrt(l*l+u*u+c*c);return h<(0,o.g)()?null:(h=1/h,l*=h,u*=h,c*=h,n=Math.sin(t),s=Math.cos(t),i=1-s,e[0]=l*l*i+s,e[1]=u*l*i+c*n,e[2]=c*l*i-u*n,e[3]=0,e[4]=l*u*i-c*n,e[5]=u*u*i+s,e[6]=c*u*i+l*n,e[7]=0,e[8]=l*c*i+u*n,e[9]=u*c*i-l*n,e[10]=c*c*i+s,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e)}function p(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=n,e[6]=r,e[7]=0,e[8]=0,e[9]=-r,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function g(e,t,r){const n=t[0],o=t[1],s=t[2],a=t[3],i=n+n,l=o+o,u=s+s,c=n*i,h=n*l,d=n*u,m=o*l,f=o*u,p=s*u,g=a*i,y=a*l,b=a*u;return e[0]=1-(m+p),e[1]=h+b,e[2]=d-y,e[3]=0,e[4]=h-b,e[5]=1-(c+p),e[6]=f+g,e[7]=0,e[8]=d+y,e[9]=f-g,e[10]=1-(c+m),e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}const y=(0,n.c)();function b(e,t,r,n){const o=t[0],s=t[1],a=t[2],i=t[3],l=o+o,u=s+s,c=a+a,h=o*l,d=o*u,m=o*c,f=s*u,p=s*c,g=a*c,y=i*l,b=i*u,w=i*c,M=n[0],v=n[1],S=n[2];return e[0]=(1-(f+g))*M,e[1]=(d+w)*M,e[2]=(m-b)*M,e[3]=0,e[4]=(d-w)*v,e[5]=(1-(h+g))*v,e[6]=(p+y)*v,e[7]=0,e[8]=(m+b)*S,e[9]=(p-y)*S,e[10]=(1-(h+f))*S,e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}function w(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e[3]=t[3]-r[3],e[4]=t[4]-r[4],e[5]=t[5]-r[5],e[6]=t[6]-r[6],e[7]=t[7]-r[7],e[8]=t[8]-r[8],e[9]=t[9]-r[9],e[10]=t[10]-r[10],e[11]=t[11]-r[11],e[12]=t[12]-r[12],e[13]=t[13]-r[13],e[14]=t[14]-r[14],e[15]=t[15]-r[15],e}function M(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[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function v(e,t){if(e===t)return!0;const r=e[0],n=e[1],s=e[2],a=e[3],i=e[4],l=e[5],u=e[6],c=e[7],h=e[8],d=e[9],m=e[10],f=e[11],p=e[12],g=e[13],y=e[14],b=e[15],w=t[0],M=t[1],v=t[2],S=t[3],k=t[4],O=t[5],x=t[6],q=t[7],C=t[8],P=t[9],N=t[10],T=t[11],Z=t[12],A=t[13],E=t[14],L=t[15],R=(0,o.g)();return Math.abs(r-w)<=R*Math.max(1,Math.abs(r),Math.abs(w))&&Math.abs(n-M)<=R*Math.max(1,Math.abs(n),Math.abs(M))&&Math.abs(s-v)<=R*Math.max(1,Math.abs(s),Math.abs(v))&&Math.abs(a-S)<=R*Math.max(1,Math.abs(a),Math.abs(S))&&Math.abs(i-k)<=R*Math.max(1,Math.abs(i),Math.abs(k))&&Math.abs(l-O)<=R*Math.max(1,Math.abs(l),Math.abs(O))&&Math.abs(u-x)<=R*Math.max(1,Math.abs(u),Math.abs(x))&&Math.abs(c-q)<=R*Math.max(1,Math.abs(c),Math.abs(q))&&Math.abs(h-C)<=R*Math.max(1,Math.abs(h),Math.abs(C))&&Math.abs(d-P)<=R*Math.max(1,Math.abs(d),Math.abs(P))&&Math.abs(m-N)<=R*Math.max(1,Math.abs(m),Math.abs(N))&&Math.abs(f-T)<=R*Math.max(1,Math.abs(f),Math.abs(T))&&Math.abs(p-Z)<=R*Math.max(1,Math.abs(p),Math.abs(Z))&&Math.abs(g-A)<=R*Math.max(1,Math.abs(g),Math.abs(A))&&Math.abs(y-E)<=R*Math.max(1,Math.abs(y),Math.abs(E))&&Math.abs(b-L)<=R*Math.max(1,Math.abs(b),Math.abs(L))}function S(e){const t=(0,o.g)(),r=e[0],n=e[1],s=e[2],a=e[4],i=e[5],l=e[6],u=e[8],c=e[9],h=e[10];return Math.abs(1-(r*r+a*a+u*u))<=t&&Math.abs(1-(n*n+i*i+c*c))<=t&&Math.abs(1-(s*s+l*l+h*h))<=t}function k(e){return 1===e[0]&&0===e[1]&&0===e[2]&&0===e[4]&&1===e[5]&&0===e[6]&&0===e[8]&&0===e[9]&&1===e[10]}const O=u,x=w;Object.freeze(Object.defineProperty({__proto__:null,add:function(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e[3]=t[3]+r[3],e[4]=t[4]+r[4],e[5]=t[5]+r[5],e[6]=t[6]+r[6],e[7]=t[7]+r[7],e[8]=t[8]+r[8],e[9]=t[9]+r[9],e[10]=t[10]+r[10],e[11]=t[11]+r[11],e[12]=t[12]+r[12],e[13]=t[13]+r[13],e[14]=t[14]+r[14],e[15]=t[15]+r[15],e},adjoint:function(e,t){const r=t[0],n=t[1],o=t[2],s=t[3],a=t[4],i=t[5],l=t[6],u=t[7],c=t[8],h=t[9],d=t[10],m=t[11],f=t[12],p=t[13],g=t[14],y=t[15];return e[0]=i*(d*y-m*g)-h*(l*y-u*g)+p*(l*m-u*d),e[1]=-(n*(d*y-m*g)-h*(o*y-s*g)+p*(o*m-s*d)),e[2]=n*(l*y-u*g)-i*(o*y-s*g)+p*(o*u-s*l),e[3]=-(n*(l*m-u*d)-i*(o*m-s*d)+h*(o*u-s*l)),e[4]=-(a*(d*y-m*g)-c*(l*y-u*g)+f*(l*m-u*d)),e[5]=r*(d*y-m*g)-c*(o*y-s*g)+f*(o*m-s*d),e[6]=-(r*(l*y-u*g)-a*(o*y-s*g)+f*(o*u-s*l)),e[7]=r*(l*m-u*d)-a*(o*m-s*d)+c*(o*u-s*l),e[8]=a*(h*y-m*p)-c*(i*y-u*p)+f*(i*m-u*h),e[9]=-(r*(h*y-m*p)-c*(n*y-s*p)+f*(n*m-s*h)),e[10]=r*(i*y-u*p)-a*(n*y-s*p)+f*(n*u-s*i),e[11]=-(r*(i*m-u*h)-a*(n*m-s*h)+c*(n*u-s*i)),e[12]=-(a*(h*g-d*p)-c*(i*g-l*p)+f*(i*d-l*h)),e[13]=r*(h*g-d*p)-c*(n*g-o*p)+f*(n*d-o*h),e[14]=-(r*(i*g-l*p)-a*(n*g-o*p)+f*(n*l-o*i)),e[15]=r*(i*d-l*h)-a*(n*d-o*h)+c*(n*l-o*i),e},copy:function(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[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e},determinant:function(e){const t=e[0],r=e[1],n=e[2],o=e[3],s=e[4],a=e[5],i=e[6],l=e[7],u=e[8],c=e[9],h=e[10],d=e[11],m=e[12],f=e[13],p=e[14],g=e[15];return(t*a-r*s)*(h*g-d*p)-(t*i-n*s)*(c*g-d*f)+(t*l-o*s)*(c*p-h*f)+(r*i-n*a)*(u*g-d*m)-(r*l-o*a)*(u*p-h*m)+(n*l-o*i)*(u*f-c*m)},equals:v,exactEquals:M,frob:function(e){return Math.sqrt(e[0]**2+e[1]**2+e[2]**2+e[3]**2+e[4]**2+e[5]**2+e[6]**2+e[7]**2+e[8]**2+e[9]**2+e[10]**2+e[11]**2+e[12]**2+e[13]**2+e[14]**2+e[15]**2)},fromQuat:function(e,t){const r=t[0],n=t[1],o=t[2],s=t[3],a=r+r,i=n+n,l=o+o,u=r*a,c=n*a,h=n*i,d=o*a,m=o*i,f=o*l,p=s*a,g=s*i,y=s*l;return e[0]=1-h-f,e[1]=c+y,e[2]=d-g,e[3]=0,e[4]=c-y,e[5]=1-u-f,e[6]=m+p,e[7]=0,e[8]=d+g,e[9]=m-p,e[10]=1-u-h,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromQuat2:function(e,t){const r=y,n=-t[0],o=-t[1],s=-t[2],a=t[3],i=t[4],l=t[5],u=t[6],c=t[7],h=n*n+o*o+s*s+a*a;return h>0?(r[0]=2*(i*a+c*n+l*s-u*o)/h,r[1]=2*(l*a+c*o+u*n-i*s)/h,r[2]=2*(u*a+c*s+i*o-l*n)/h):(r[0]=2*(i*a+c*n+l*s-u*o),r[1]=2*(l*a+c*o+u*n-i*s),r[2]=2*(u*a+c*s+i*o-l*n)),g(e,t,r),e},fromRotation:f,fromRotationTranslation:g,fromRotationTranslationScale:b,fromRotationTranslationScaleOrigin:function(e,t,r,n,o){const s=t[0],a=t[1],i=t[2],l=t[3],u=s+s,c=a+a,h=i+i,d=s*u,m=s*c,f=s*h,p=a*c,g=a*h,y=i*h,b=l*u,w=l*c,M=l*h,v=n[0],S=n[1],k=n[2],O=o[0],x=o[1],q=o[2],C=(1-(p+y))*v,P=(m+M)*v,N=(f-w)*v,T=(m-M)*S,Z=(1-(d+y))*S,A=(g+b)*S,E=(f+w)*k,L=(g-b)*k,R=(1-(d+p))*k;return e[0]=C,e[1]=P,e[2]=N,e[3]=0,e[4]=T,e[5]=Z,e[6]=A,e[7]=0,e[8]=E,e[9]=L,e[10]=R,e[11]=0,e[12]=r[0]+O-(C*O+T*x+E*q),e[13]=r[1]+x-(P*O+Z*x+L*q),e[14]=r[2]+q-(N*O+A*x+R*q),e[15]=1,e},fromScaling:function(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=t[1],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=t[2],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromTranslation:m,fromXRotation:p,fromYRotation:function(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=0,e[2]=-r,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=r,e[9]=0,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromZRotation:function(e,t){const r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=r,e[2]=0,e[3]=0,e[4]=-r,e[5]=n,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},frustum:function(e,t,r,n,o,s,a){const i=1/(r-t),l=1/(o-n),u=1/(s-a);return e[0]=2*s*i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*s*l,e[6]=0,e[7]=0,e[8]=(r+t)*i,e[9]=(o+n)*l,e[10]=(a+s)*u,e[11]=-1,e[12]=0,e[13]=0,e[14]=a*s*2*u,e[15]=0,e},getRotation:function(e,t){const r=t[0]+t[5]+t[10];let n=0;return r>0?(n=2*Math.sqrt(r+1),e[3]=.25*n,e[0]=(t[6]-t[9])/n,e[1]=(t[8]-t[2])/n,e[2]=(t[1]-t[4])/n):t[0]>t[5]&&t[0]>t[10]?(n=2*Math.sqrt(1+t[0]-t[5]-t[10]),e[3]=(t[6]-t[9])/n,e[0]=.25*n,e[1]=(t[1]+t[4])/n,e[2]=(t[8]+t[2])/n):t[5]>t[10]?(n=2*Math.sqrt(1+t[5]-t[0]-t[10]),e[3]=(t[8]-t[2])/n,e[0]=(t[1]+t[4])/n,e[1]=.25*n,e[2]=(t[6]+t[9])/n):(n=2*Math.sqrt(1+t[10]-t[0]-t[5]),e[3]=(t[1]-t[4])/n,e[0]=(t[8]+t[2])/n,e[1]=(t[6]+t[9])/n,e[2]=.25*n),e},getScaling:function(e,t){const r=t[0],n=t[1],o=t[2],s=t[4],a=t[5],i=t[6],l=t[8],u=t[9],c=t[10];return e[0]=Math.sqrt(r*r+n*n+o*o),e[1]=Math.sqrt(s*s+a*a+i*i),e[2]=Math.sqrt(l*l+u*u+c*c),e},getTranslation:function(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e},hasIdentityRotation:k,identity:a,invert:l,invertOrIdentity:function(e,t){return l(e,t)||a(e),e},isOrthoNormal:S,lookAt:function(e,t,r,n){const s=t[0],i=t[1],l=t[2];let u=s-r[0],c=i-r[1],h=l-r[2];const d=(0,o.g)();if(Math.abs(u)<d&&Math.abs(c)<d&&Math.abs(h)<d)return void a(e);let m=1/Math.sqrt(u*u+c*c+h*h);u*=m,c*=m,h*=m;const f=n[0],p=n[1],g=n[2];let y=p*h-g*c,b=g*u-f*h,w=f*c-p*u;m=Math.sqrt(y*y+b*b+w*w),m?(m=1/m,y*=m,b*=m,w*=m):(y=0,b=0,w=0);let M=c*w-h*b,v=h*y-u*w,S=u*b-c*y;m=Math.sqrt(M*M+v*v+S*S),m?(m=1/m,M*=m,v*=m,S*=m):(M=0,v=0,S=0),e[0]=y,e[1]=M,e[2]=u,e[3]=0,e[4]=b,e[5]=v,e[6]=c,e[7]=0,e[8]=w,e[9]=S,e[10]=h,e[11]=0,e[12]=-(y*s+b*i+w*l),e[13]=-(M*s+v*i+S*l),e[14]=-(u*s+c*i+h*l),e[15]=1},mul:O,multiply:u,multiplyScalar:function(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*r,e[9]=t[9]*r,e[10]=t[10]*r,e[11]=t[11]*r,e[12]=t[12]*r,e[13]=t[13]*r,e[14]=t[14]*r,e[15]=t[15]*r,e},multiplyScalarAndAdd:function(e,t,r,n){return e[0]=t[0]+r[0]*n,e[1]=t[1]+r[1]*n,e[2]=t[2]+r[2]*n,e[3]=t[3]+r[3]*n,e[4]=t[4]+r[4]*n,e[5]=t[5]+r[5]*n,e[6]=t[6]+r[6]*n,e[7]=t[7]+r[7]*n,e[8]=t[8]+r[8]*n,e[9]=t[9]+r[9]*n,e[10]=t[10]+r[10]*n,e[11]=t[11]+r[11]*n,e[12]=t[12]+r[12]*n,e[13]=t[13]+r[13]*n,e[14]=t[14]+r[14]*n,e[15]=t[15]+r[15]*n,e},ortho:function(e,t,r,n,o,s,a){const i=1/(t-r),l=1/(n-o),u=1/(s-a);return e[0]=-2*i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*u,e[11]=0,e[12]=(t+r)*i,e[13]=(o+n)*l,e[14]=(a+s)*u,e[15]=1,e},perspective:function(e,t,r,n,o){const s=1/Math.tan(t/2);let a;return e[0]=s/r,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=o&&o!==1/0?(a=1/(n-o),e[10]=(o+n)*a,e[14]=2*o*n*a):(e[10]=-1,e[14]=-2*n),e},perspectiveFromFieldOfView:function(e,t,r,n){const o=Math.tan(t.upDegrees*Math.PI/180),s=Math.tan(t.downDegrees*Math.PI/180),a=Math.tan(t.leftDegrees*Math.PI/180),i=Math.tan(t.rightDegrees*Math.PI/180),l=2/(a+i),u=2/(o+s);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=u,e[6]=0,e[7]=0,e[8]=-(a-i)*l*.5,e[9]=(o-s)*u*.5,e[10]=n/(r-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*r/(r-n),e[15]=0,e},rotate:d,rotateX:function(e,t,r){const n=Math.sin(r),o=Math.cos(r),s=t[4],a=t[5],i=t[6],l=t[7],u=t[8],c=t[9],h=t[10],d=t[11];return t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[4]=s*o+u*n,e[5]=a*o+c*n,e[6]=i*o+h*n,e[7]=l*o+d*n,e[8]=u*o-s*n,e[9]=c*o-a*n,e[10]=h*o-i*n,e[11]=d*o-l*n,e},rotateY:function(e,t,r){const n=Math.sin(r),o=Math.cos(r),s=t[0],a=t[1],i=t[2],l=t[3],u=t[8],c=t[9],h=t[10],d=t[11];return t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=s*o-u*n,e[1]=a*o-c*n,e[2]=i*o-h*n,e[3]=l*o-d*n,e[8]=s*n+u*o,e[9]=a*n+c*o,e[10]=i*n+h*o,e[11]=l*n+d*o,e},rotateZ:function(e,t,r){const n=Math.sin(r),o=Math.cos(r),s=t[0],a=t[1],i=t[2],l=t[3],u=t[4],c=t[5],h=t[6],d=t[7];return t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=s*o+u*n,e[1]=a*o+c*n,e[2]=i*o+h*n,e[3]=l*o+d*n,e[4]=u*o-s*n,e[5]=c*o-a*n,e[6]=h*o-i*n,e[7]=d*o-l*n,e},scale:h,set:s,str:function(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"},sub:x,subtract:w,targetTo:function(e,t,r,n){const o=t[0],s=t[1],a=t[2],i=n[0],l=n[1],u=n[2];let c=o-r[0],h=s-r[1],d=a-r[2],m=c*c+h*h+d*d;m>0&&(m=1/Math.sqrt(m),c*=m,h*=m,d*=m);let f=l*d-u*h,p=u*c-i*d,g=i*h-l*c;return m=f*f+p*p+g*g,m>0&&(m=1/Math.sqrt(m),f*=m,p*=m,g*=m),e[0]=f,e[1]=p,e[2]=g,e[3]=0,e[4]=h*g-d*p,e[5]=d*f-c*g,e[6]=c*p-h*f,e[7]=0,e[8]=c,e[9]=h,e[10]=d,e[11]=0,e[12]=o,e[13]=s,e[14]=a,e[15]=1,e},translate:c,transpose:i},Symbol.toStringTag,{value:"Module"}))},35270:(e,t,r)=>{r.d(t,{B7:()=>l,St:()=>o,VL:()=>a,h$:()=>s,rW:()=>u});const n={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function o(e){return!!n[e]||!!n[e.toLowerCase()]}function s(e){return n[e]??n[e.toLowerCase()]}function a(e){return[...s(e)]}function i(e,t,r){r<0&&++r,r>1&&--r;const n=6*r;return n<1?e+(t-e)*n:2*r<1?t:3*r<2?e+(t-e)*(2/3-r)*6:e}function l(e,t,r,n=1){const o=(e%360+360)%360/360,s=r<=.5?r*(t+1):r+t-r*t,a=2*r-s;return[Math.round(255*i(a,s,o+1/3)),Math.round(255*i(a,s,o)),Math.round(255*i(a,s,o-1/3)),n]}function u(e){const t=e.length>5,r=t?8:4,n=(1<<r)-1,o=t?1:17,s=t?9===e.length:5===e.length;let a=Number("0x"+e.substr(1));if(isNaN(a))return null;const i=[0,0,0,1];let l;return s&&(l=a&n,a>>=r,i[3]=o*l/255),l=a&n,a>>=r,i[2]=o*l,l=a&n,a>>=r,i[1]=o*l,l=a&n,a>>=r,i[0]=o*l,i}},10661:(e,t,r)=>{r.d(t,{s:()=>o});var n=r(42100);class o extends n.s{notify(){const e=this._observers;if(e&&e.length>0){const t=e.slice();for(const e of t)e.onInvalidated(),e.onCommitted()}}}},66577:(e,t,r)=>{r.d(t,{qM:()=>c});var n=r(75215),o=r(6570),s=r(9361),a=r(65091),i=r(94139),l=r(38913),u=r(58901);r(82971),r(86973),r(33955);const c={base:s.Z,key:"type",typeMap:{extent:o.Z,multipoint:a.Z,point:i.Z,polyline:u.Z,polygon:l.Z}};(0,n.N7)(c)},33955:(e,t,r)=>{r.d(t,{Ji:()=>p,YX:()=>u,aW:()=>c,im:()=>f,l9:()=>d,oU:()=>m,q9:()=>y,wp:()=>h});var n=r(6570),o=r(9361),s=r(65091),a=r(94139),i=r(38913),l=r(58901);function u(e){return void 0!==e.xmin&&void 0!==e.ymin&&void 0!==e.xmax&&void 0!==e.ymax}function c(e){return void 0!==e.points}function h(e){return void 0!==e.x&&void 0!==e.y}function d(e){return void 0!==e.paths}function m(e){return void 0!==e.rings}function f(e){return null==e?null:e instanceof o.Z?e:h(e)?a.Z.fromJSON(e):d(e)?l.Z.fromJSON(e):m(e)?i.Z.fromJSON(e):c(e)?s.Z.fromJSON(e):u(e)?n.Z.fromJSON(e):null}function p(e){return e?h(e)?"esriGeometryPoint":d(e)?"esriGeometryPolyline":m(e)?"esriGeometryPolygon":u(e)?"esriGeometryEnvelope":c(e)?"esriGeometryMultipoint":null:null}const g={esriGeometryPoint:a.Z,esriGeometryPolyline:l.Z,esriGeometryPolygon:i.Z,esriGeometryEnvelope:n.Z,esriGeometryMultipoint:s.Z};function y(e){return e&&g[e]||null}},86973:(e,t,r)=>{r.d(t,{M:()=>o,P:()=>s});var n=r(35454);const o=(0,n.w)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),s=(0,n.w)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"})},61576:(e,t,r)=>{r.r(t),r.d(t,{default:()=>g}),r(66577);var n=r(18571),o=r(5847),s=r(75993),a=r(55914),i=r(40932),l=r(73506),u=r(15612),c=r(80676),h=r(87521),d=r(72758),m=r(23808),f=r(6570),p=r(94139);class g{convertVectorFieldData(e){const t=o.Z.fromJSON(e.pixelBlock),r=(0,c.KC)(t,e.type);return Promise.resolve(null!=r?r.toJSON():null)}computeStatisticsHistograms(e){const t=o.Z.fromJSON(e.pixelBlock),r=(0,u.js)(t);return Promise.resolve(r)}async decode(e){const t=await(0,s.J)(e.data,e.options);return t&&t.toJSON()}symbolize(e){e.pixelBlock=o.Z.fromJSON(e.pixelBlock),e.extent=e.extent?f.Z.fromJSON(e.extent):null;const t=this.symbolizer.symbolize(e);return Promise.resolve(null!=t?t.toJSON():null)}async updateSymbolizer(e){this.symbolizer=d.Z.fromJSON(e.symbolizerJSON),e.histograms&&"rasterStretch"===this.symbolizer?.rendererJSON.type&&(this.symbolizer.rendererJSON.histograms=e.histograms)}async updateRasterFunction(e){this.rasterFunction=(0,i.Ue)(e.rasterFunctionJSON)}async process(e){const t=this.rasterFunction.process({extent:f.Z.fromJSON(e.extent),primaryPixelBlocks:e.primaryPixelBlocks.map((e=>null!=e?o.Z.fromJSON(e):null)),primaryPixelSizes:e.primaryPixelSizes?.map((e=>null!=e?p.Z.fromJSON(e):null)),primaryRasterIds:e.primaryRasterIds});return null!=t?t.toJSON():null}stretch(e){const t=this.symbolizer.simpleStretch(o.Z.fromJSON(e.srcPixelBlock),e.stretchParams);return Promise.resolve(null!=t&&t.toJSON())}estimateStatisticsHistograms(e){const t=(0,u.Hv)(o.Z.fromJSON(e.srcPixelBlock));return Promise.resolve(t)}split(e){const t=(0,a.Vl)(o.Z.fromJSON(e.srcPixelBlock),e.tileSize,e.maximumPyramidLevel);return t&&t.forEach(((e,r)=>{t.set(r,e?.toJSON())})),Promise.resolve(t)}async mosaicAndTransform(e){const t=e.srcPixelBlocks.map((e=>e?new o.Z(e):null)),r=(0,a.us)(t,e.srcMosaicSize,{blockWidths:e.blockWidths,alignmentInfo:e.alignmentInfo,clipOffset:e.clipOffset,clipSize:e.clipSize});let n,s=r;return e.coefs&&(s=(0,a.Uk)(r,e.destDimension,e.coefs,e.sampleSpacing,e.interpolation)),e.projectDirections&&e.gcsGrid&&(n=(0,a.Qh)(e.destDimension,e.gcsGrid),s=(0,c.xQ)(s,e.isUV?"vector-uv":"vector-magdir",n)),{pixelBlock:s?.toJSON(),localNorthDirections:n}}async createFlowMesh(e,t){const r={data:new Float32Array(e.flowData.buffer),mask:new Uint8Array(e.flowData.maskBuffer),width:e.flowData.width,height:e.flowData.height},{vertexData:n,indexData:o}=await(0,m.GE)(e.meshType,e.simulationSettings,r,t.signal);return{result:{vertexBuffer:n.buffer,indexBuffer:o.buffer},transferList:[n.buffer,o.buffer]}}async getProjectionOffsetGrid(e){const t=f.Z.fromJSON(e.projectedExtent),r=f.Z.fromJSON(e.srcBufferExtent);let o=null;e.datumTransformationSteps&&(o=new n.Z({steps:e.datumTransformationSteps})),(e.includeGCSGrid||(0,l.Mk)(t.spatialReference,r.spatialReference,o))&&await(0,l.zD)();const s=e.rasterTransform?(0,h.c)(e.rasterTransform):null;return(0,l.Qp)({...e,projectedExtent:t,srcBufferExtent:r,datumTransformation:o,rasterTransform:s})}}},3172:(e,t,r)=>{r.r(t),r.d(t,{default:()=>m});var n=r(68773),o=r(40330),s=r(20102),a=r(80442),i=r(22974),l=r(95330),u=r(81271),c=r(19745),h=r(71058),d=r(85958);async function m(e,t){e instanceof URL&&(e=e.toString()),t?.query instanceof URLSearchParams&&(t.query=(0,u.u0)(t.query.toString().replaceAll("+"," ")));const i=(0,u.HK)(e),c=(0,u.jc)(e);c||i||(e=(0,u.Fv)(e));const y={url:e,requestOptions:{...t}};let b=(0,u.oh)(e);if(b){const e=await async function(e,t){if(null!=e.responseData)return e.responseData;if(e.headers&&(t.requestOptions.headers={...t.requestOptions.headers,...e.headers}),e.query&&(t.requestOptions.query={...t.requestOptions.query,...e.query}),e.before){let r,n;try{n=await e.before(t)}catch(e){r=k("request:interceptor",e,t)}if((n instanceof Error||n instanceof s.Z)&&(r=k("request:interceptor",n,t)),r)throw e.error&&e.error(r),r;return n}}(b,y);if(null!=e)return{data:e,getHeader:M,httpStatus:200,requestOptions:y.requestOptions,url:y.url};b.after||b.error||(b=null)}if(e=y.url,"image"===(t=y.requestOptions).responseType&&((0,a.Z)("host-webworker")||(0,a.Z)("host-node")))throw k("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),y);if("head"===t.method){if(t.body)throw k("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),y);if(i||c)throw k("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),y)}if(await async function(){(0,a.Z)("host-webworker")?f||(f=await r.e(9884).then(r.bind(r,29884))):m._abortableFetch||(m._abortableFetch=globalThis.fetch.bind(globalThis))}(),f)return f.execute(e,t);const w=new AbortController;(0,l.fu)(t,(()=>w.abort()));const v={controller:w,credential:void 0,credentialToken:void 0,fetchOptions:void 0,hasToken:!1,interceptor:b,params:y,redoRequest:!1,useIdentity:p.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},S=await async function(e){let t,r;await async function(e){const t=e.params.url,r=e.params.requestOptions,s=e.controller.signal,a=r.body;let i=null,u=null;if(g&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(i=new FormData(a))),"string"==typeof a&&(u=a),e.fetchOptions={cache:r.cacheBust&&!("polyfill"in m._abortableFetch)?"no-cache":"default",credentials:"same-origin",headers:r.headers||{},method:"head"===r.method?"HEAD":"GET",mode:"cors",priority:p.priority,redirect:"follow",signal:s},(i||u)&&(e.fetchOptions.body=i||u),"anonymous"===r.authMode&&(e.useIdentity=!1),e.hasToken=!!(/token=/i.test(t)||r.query?.token||i?.get("token")),!e.hasToken&&n.default.apiKey&&(0,h.r)(t)&&(r.query||(r.query={}),r.query.token=n.default.apiKey,e.hasToken=!0),e.useIdentity&&!e.hasToken&&!e.credentialToken&&!x(t)&&!(0,l.Hc)(s)){let n;"immediate"===r.authMode?(await O(),n=await o.id.getCredential(t,{signal:s}),e.credential=n):"no-prompt"===r.authMode?(await O(),n=await o.id.getCredential(t,{prompt:!1,signal:s}).catch((()=>{})),e.credential=n):o.id&&(n=o.id.findCredential(t)),n&&(e.credentialToken=n.token,e.useSSL=!!n.ssl)}}(e);try{do{[t,r]=await q(e)}while(!await P(e,t,r))}catch(r){const n=k("request:server",r,e.params,t);throw n.details.ssl=e.useSSL,e.interceptor?.error&&e.interceptor.error(n),n}const s=e.params.url;if(r&&/\/sharing\/rest\/(accounts|portals)\/self/i.test(s)){if(!e.hasToken&&!e.credentialToken&&r.user?.username&&!(0,u.kl)(s)){const e=(0,u.P$)(s,!0);e&&p.trustedServers.push(e)}Array.isArray(r.authorizedCrossOriginNoCorsDomains)&&(0,d.Hu)(r.authorizedCrossOriginNoCorsDomains)}const a=e.credential;if(a&&o.id){const e=o.id.findServerInfo(a.server);let t=e?.owningSystemUrl;if(t){t=t.replace(/\/?$/,"/sharing");const e=o.id.findCredential(t,a.userId);e&&-1===o.id._getIdenticalSvcIdx(t,e)&&e.resources.unshift(t)}}return{data:r,getHeader:t?e=>t?.headers.get(e):M,httpStatus:t?.status??200,requestOptions:e.params.requestOptions,ssl:e.useSSL,url:e.params.url}}(v);return b?.after?.(S),S}let f;const p=n.default.request,g="FormData"in globalThis,y=[499,498,403,401],b=["COM_0056","COM_0057","SB_0008"],w=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],M=()=>null,v=Symbol();function S(e){const t=(0,u.P$)(e);return!t||t.endsWith(".arcgis.com")||m._corsServers.includes(t)||(0,u.kl)(t)}function k(e,t,r,n){let o="Error";const a={url:r.url,requestOptions:r.requestOptions,getHeader:M,ssl:!1};if(t instanceof s.Z)return t.details?(t.details=(0,i.d9)(t.details),t.details.url=r.url,t.details.requestOptions=r.requestOptions):t.details=a,t;if(t){const e=n&&(e=>n.headers.get(e)),r=n?.status,s=t.message;s&&(o=s),e&&(a.getHeader=e),a.httpStatus=(null!=t.httpCode?t.httpCode:t.code)||r||0,a.subCode=t.subcode,a.messageCode=t.messageCode,"string"==typeof t.details?a.messages=[t.details]:a.messages=t.details,a.raw=v in t?t[v]:t}return(0,l.D_)(t)?(0,l.zE)():new s.Z(e,o,a)}async function O(){o.id||await Promise.all([r.e(7126),r.e(6261),r.e(9255),r.e(1400),r.e(450)]).then(r.bind(r,73660))}function x(e){return w.some((t=>t.test(e)))}async function q(e){let t=e.params.url;const r=e.params.requestOptions,n=e.fetchOptions??{},s=(0,u.jc)(t)||(0,u.HK)(t),i=r.responseType||"json",h=s?0:null!=r.timeout?r.timeout:p.timeout;let f=!1;if(!s){e.useSSL&&(t=(0,u.hO)(t)),r.cacheBust&&"default"===n.cache&&(t=(0,u.ZN)(t,"request.preventCache",Date.now()));let s={...r.query};e.credentialToken&&(s.token=e.credentialToken);let i=(0,u.B7)(s);(0,a.Z)("esri-url-encodes-apostrophe")&&(i=i.replaceAll("'","%27"));const l=t.length+1+i.length;let h;f="delete"===r.method||"post"===r.method||"put"===r.method||!!r.body||l>p.maxUrlLength;const m=r.useProxy||!!(0,u.ed)(t);if(m){const e=(0,u.b7)(t);h=e.path,!f&&h.length+1+l>p.maxUrlLength&&(f=!0),e.query&&(s={...e.query,...s})}if("HEAD"===n.method&&(f||m)){if(f){if(l>p.maxUrlLength)throw k("request:invalid-parameters",new Error("URL exceeds maximum length"),e.params);throw k("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),e.params)}if(m)throw k("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),e.params)}if(f?(n.method="delete"===r.method?"DELETE":"put"===r.method?"PUT":"POST",r.body?t=(0,u.fl)(t,s):(n.body=(0,u.B7)(s),n.headers||(n.headers={}),n.headers["Content-Type"]="application/x-www-form-urlencoded")):t=(0,u.fl)(t,s),m&&(e.useProxy=!0,t=`${h}?${t}`),s.token&&g&&n.body instanceof FormData&&!(0,c.P)(t)&&n.body.set("token",s.token),r.hasOwnProperty("withCredentials"))e.withCredentials=r.withCredentials;else if(!(0,u.D6)(t,(0,u.TI)()))if((0,u.kl)(t))e.withCredentials=!0;else if(o.id){const r=o.id.findServerInfo(t);r?.webTierAuth&&(e.withCredentials=!0)}e.withCredentials&&(n.credentials="include",(0,d.jH)(t)&&await(0,d.jz)(f?(0,u.fl)(t,s):t))}let y,b,w=0,M=!1;h>0&&(w=setTimeout((()=>{M=!0,e.controller.abort()}),h));try{if("native-request-init"===r.responseType)b=n,b.url=t;else if("image"!==r.responseType||"default"!==n.cache||"GET"!==n.method||f||function(e){if(e)for(const t of Object.getOwnPropertyNames(e))if(e[t])return!0;return!1}(r.headers)||!s&&!e.useProxy&&p.proxyUrl&&!S(t)){if(y=await m._abortableFetch(t,n),e.useProxy||function(e){const t=(0,u.P$)(e);t&&!m._corsServers.includes(t)&&m._corsServers.push(t)}(t),"native"===r.responseType)b=y;else if("HEAD"!==n.method)if(y.ok){switch(i){case"array-buffer":b=await y.arrayBuffer();break;case"blob":case"image":b=await y.blob();break;default:b=await y.text()}if(w&&(clearTimeout(w),w=0),"json"===i||"xml"===i||"document"===i)if(b)switch(i){case"json":b=JSON.parse(b);break;case"xml":b=C(b,"application/xml");break;case"document":b=C(b,"text/html")}else b=null;if(b){if("array-buffer"===i||"blob"===i){const e=y.headers.get("Content-Type");if(e&&/application\/json|text\/plain/i.test(e)&&b["blob"===i?"size":"byteLength"]<=750)try{const e=await new Response(b).json();e.error&&(b=e)}catch{}}"image"===i&&b instanceof Blob&&(b=await N(URL.createObjectURL(b),e,!0))}}else{b=await y.text();try{b=JSON.parse(b)}catch{}}}else b=await N(t,e)}catch(n){if("AbortError"===n.name){if(M)throw(0,d.Tf)();throw(0,l.zE)("Request canceled")}if(!(!y&&n instanceof TypeError&&p.proxyUrl)||r.body||"delete"===r.method||"head"===r.method||"post"===r.method||"put"===r.method||e.useProxy||S(t))throw n;e.redoRequest=!0,(0,u.tD)({proxyUrl:p.proxyUrl,urlPrefix:(0,u.P$)(t)??""})}finally{w&&clearTimeout(w)}return[y,b]}function C(e,t){let r;try{r=(new DOMParser).parseFromString(e,t)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function P(e,t,r){if(e.redoRequest)return e.redoRequest=!1,!1;const n=e.params.requestOptions;if(!t||"native"===n.responseType||"native-request-init"===n.responseType)return!0;let s,a;if(r&&(r.error?s=r.error:"error"===r.status&&Array.isArray(r.messages)&&(s={...r},s[v]=r,s.details=r.messages)),!s&&!t.ok)throw s=new Error(`Unable to load ${t.url} status: ${t.status}`),s[v]=r,s;let i,l=null;s&&(a=Number(s.code),l=s.hasOwnProperty("subcode")?Number(s.subcode):null,i=s.messageCode,i=i?.toUpperCase());const u=n.authMode;if(403===a&&(4===l||s.message?.toLowerCase().includes("ssl")&&!s.message.toLowerCase().includes("permission"))){if(!e.useSSL)return e.useSSL=!0,!1}else if(!e.hasToken&&e.useIdentity&&("no-prompt"!==u||498===a)&&void 0!==a&&y.includes(a)&&!x(e.params.url)&&(403!==a||i&&!b.includes(i)&&(null==l||2===l&&e.credentialToken))){await O();try{const t=await o.id.getCredential(e.params.url,{error:k("request:server",s,e.params),prompt:"no-prompt"!==u,signal:e.controller.signal,token:e.credentialToken});return e.credential=t,e.credentialToken=t.token,e.useSSL=e.useSSL||t.ssl,!1}catch(t){if("no-prompt"===u)return e.credential=void 0,e.credentialToken=void 0,!1;s=t}}if(s)throw s;return!0}function N(e,t,r=!1){const n=t.controller.signal,o=new Image;return t.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchPriority=p.priority,o.src=e,(0,d.fY)(o,e,r,n)}m._abortableFetch=null,m._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"]},98046:(e,t,r)=>{r.d(t,{Z:()=>m});var n,o=r(43697),s=r(22303),a=r(22974),i=r(5600),l=r(75215),u=r(36030),c=r(52011),h=r(899);let d=n=class extends h.Z{constructor(e){super(e),this.algorithm=null,this.fromColor=null,this.toColor=null,this.type="algorithmic"}clone(){return new n({fromColor:(0,a.d9)(this.fromColor),toColor:(0,a.d9)(this.toColor),algorithm:this.algorithm})}};(0,o._)([(0,u.J)({esriCIELabAlgorithm:"cie-lab",esriHSVAlgorithm:"hsv",esriLabLChAlgorithm:"lab-lch"})],d.prototype,"algorithm",void 0),(0,o._)([(0,i.Cb)({type:s.Z,json:{type:[l.z8],write:!0}})],d.prototype,"fromColor",void 0),(0,o._)([(0,i.Cb)({type:s.Z,json:{type:[l.z8],write:!0}})],d.prototype,"toColor",void 0),(0,o._)([(0,i.Cb)({type:["algorithmic"]})],d.prototype,"type",void 0),d=n=(0,o._)([(0,c.j)("esri.rest.support.AlgorithmicColorRamp")],d);const m=d},899:(e,t,r)=>{r.d(t,{Z:()=>l});var n=r(43697),o=r(96674),s=r(5600),a=(r(75215),r(67676),r(80442),r(52011));let i=class extends o.wq{constructor(e){super(e),this.type=null}};(0,n._)([(0,s.Cb)({readOnly:!0,json:{read:!1,write:!0}})],i.prototype,"type",void 0),i=(0,n._)([(0,a.j)("esri.rest.support.ColorRamp")],i);const l=i},1515:(e,t,r)=>{r.d(t,{Z:()=>h});var n,o=r(43697),s=r(22974),a=r(5600),i=(r(75215),r(52011)),l=r(98046),u=r(899);let c=n=class extends u.Z{constructor(e){super(e),this.colorRamps=null,this.type="multipart"}clone(){return new n({colorRamps:(0,s.d9)(this.colorRamps)})}};(0,o._)([(0,a.Cb)({type:[l.Z],json:{write:!0}})],c.prototype,"colorRamps",void 0),(0,o._)([(0,a.Cb)({type:["multipart"]})],c.prototype,"type",void 0),c=n=(0,o._)([(0,i.j)("esri.rest.support.MultipartColorRamp")],c);const h=c},94593:(e,t,r)=>{r.d(t,{V:()=>a,i:()=>i});var n=r(98046),o=r(899),s=r(1515);const a={key:"type",base:o.Z,typeMap:{algorithmic:n.Z,multipart:s.Z}};function i(e){return e&&e.type?"algorithmic"===e.type?n.Z.fromJSON(e):"multipart"===e.type?s.Z.fromJSON(e):null:null}},71058:(e,t,r)=>{r.d(t,{r:()=>s});var n=r(81271);const o=["elevation3d.arcgis.com","js.arcgis.com","jsdev.arcgis.com","jsqa.arcgis.com","static.arcgis.com"];function s(e){const t=(0,n.P$)(e,!0);return!!t&&t.endsWith(".arcgis.com")&&!o.includes(t)&&!e.endsWith("/sharing/rest/generateToken")}},85958:(e,t,r)=>{r.d(t,{Hu:()=>h,Tf:()=>c,fY:()=>i,jH:()=>d,jz:()=>m});var n=r(68773),o=r(80442),s=r(95330),a=r(81271);function i(e,t,r=!1,n){return new Promise(((a,i)=>{if((0,s.Hc)(n))return void i(l());let u=()=>{d(),i(new Error(`Unable to load ${t}`))},c=()=>{const t=e;d(),a(t)},h=()=>{if(!e)return;const t=e;d(),t.src="",i(l())};const d=()=>{(0,o.Z)("esri-image-decode")||(e.removeEventListener("error",u),e.removeEventListener("load",c)),u=null,c=null,e=null,null!=n&&n.removeEventListener("abort",h),h=null,r&&URL.revokeObjectURL(t)};null!=n&&n.addEventListener("abort",h),(0,o.Z)("esri-image-decode")?e.decode().then(c,u):(e.addEventListener("error",u),e.addEventListener("load",c))}))}function l(){try{return new DOMException("Aborted","AbortError")}catch{const e=new Error;return e.name="AbortError",e}}const u="Timeout exceeded";function c(){return new Error(u)}function h(e){n.default.request.crossOriginNoCorsDomains||(n.default.request.crossOriginNoCorsDomains={});const t=n.default.request.crossOriginNoCorsDomains;for(let r of e)r=r.toLowerCase(),/^https?:\/\//.test(r)?t[(0,a.P$)(r)??""]=0:(t[(0,a.P$)("http://"+r)??""]=0,t[(0,a.P$)("https://"+r)??""]=0)}function d(e){const t=n.default.request.crossOriginNoCorsDomains;if(t){let r=(0,a.P$)(e);if(r)return r=r.toLowerCase(),!(0,a.D6)(r,(0,a.TI)())&&t[r]<Date.now()-36e5}return!1}async function m(e){const t=n.default.request.crossOriginNoCorsDomains,r=(0,a.P$)(e);t&&r&&(t[r.toLowerCase()]=Date.now());const o=(0,a.mN)(e);e=o.path,"json"===o.query?.f&&(e+="?f=json");try{await fetch(e,{mode:"no-cors",credentials:"include"})}catch{}}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6946],{36946:(e,t,s)=>{s.d(t,{uploadAssets:()=>h});var a=s(3172),r=s(20102),n=s(92604),o=s(95330),i=s(81271),l=s(41123),u=s(84470),c=s(66677);const p=1e6,d=20*p,f=2e9,y=3;async function w({data:e,name:t,description:s},r,n){let l=null;try{const u=(0,i.v_)(r,"uploads"),w=(0,i.v_)(u,"info"),{data:m}=await(0,a.default)(w,{query:{f:"json"},responseType:"json"});(0,o.k_)(n);const h=(0,c.M8)(r),g=m.maxUploadFileSize*p,T=h?f:g,v=h?Math.min(d,g):d;if(e.size>T)throw new Error("Data too large");const b=(0,i.v_)(u,"register"),{data:E}=await(0,a.default)(b,{query:{f:"json",itemName:t,description:s},responseType:"json",method:"post"});if((0,o.k_)(n),!E.success)throw new Error("Registration failed");const{itemID:_}=E.item;l=(0,i.v_)(u,_);const $=(0,i.v_)(l,"uploadPart"),j=Math.ceil(e.size/v),F=new Array;for(let t=0;t<j;++t)F.push(e.slice(t*v,Math.min((t+1)*v,e.size)));const k=F.slice().reverse(),D=new Array,U=async()=>{for(;0!==k.length;){const e=F.length-k.length,t=k.pop(),s=new FormData;s.append("f","json"),s.append("file",t),s.append("partId",`${e}`);const{data:r}=await(0,a.default)($,{timeout:0,body:s,responseType:"json",method:"post"});if((0,o.k_)(n),!r.success)throw new Error("Part upload failed")}};for(let e=0;e<y&&0!==k.length;++e)D.push(U());await Promise.all(D);const x=(0,i.v_)(l,"commit"),{data:A}=await(0,a.default)(x,{query:{f:"json",parts:F.map(((e,t)=>t)).join(",")},responseType:"json",method:"post"});if((0,o.k_)(n),!A.success)throw new Error("Commit failed");return A.item}catch(e){if(null!=l){const e=(0,i.v_)(l,"delete");await(0,a.default)(e,{query:{f:"json"},responseType:"json",method:"post"})}throw e}}var m=s(2981);async function h(e,t,s){return e.length?Promise.all(e.map((e=>async function(e,{layer:t,ongoingUploads:s},a){const n=s.get(e);if(n)return n;if(!function(e){return!!e.infoFor3D&&!!e.url}(t))throw new r.Z(`${t.type}-layer:upload-failure`,"Layer does not support asset uploads.",new Error);if(function(e,t){const{parsedUrl:s}=t;return null!=s&&e.metadata.externalSources.some((e=>(0,u.JG)(e,s)))}(e,t))return e;const i=async function(e,t,s){const{metadata:a}=e,{displaySource:n}=a,i=g(n?.source,t),u=!!i,c=a.externalSources.length>0,p=u?async function(e,t,s){return{source:await v(e,t,s),original:!0}}(i,t,s):c?async function(e,t,s){const a=_(t),{externalSources:n}=e.metadata,o=function(e,t){for(const s of e){const e=g(s.source,t);if(e)return e}return null}(n,t);if(!o)throw new r.Z(`${t.type}-layer:upload-failure`,"Could not find an external source that is supported by the service.",new Error);const i=await v(o,t,s);return e.addExternalSources([{source:i,original:!0}]),{source:await E(i,t,a)}}(e,t,s):async function(e,t,s){const a=async function(e,t,s){const a=_(t),r=await e.load(s),n=await r.toBinaryGLTF({ignoreLocalTransform:!0});(0,o.k_)(s);const i=await n.buffer();return(0,o.k_)(s),{blob:new Blob([i.data],{type:i.type}),assetName:`${(0,l.z)()}.glb`,assetType:a}}(e,t,s);return{source:await b([a],t,s),extent:e.extent.clone(),original:!0}}(e,t,s),d=await p;return(0,o.k_)(s),e.addExternalSources([d]),e}(e,t,a);s.set(e,i);try{await i}finally{s.delete(e)}return e}(e,t,s)))):[]}function g(e,t){if(!e)return null;const{infoFor3D:{supportedFormats:s,editFormats:a}}=t,r=(0,u.zE)(e),n=new Array;let o=!1;for(let e=0;e<r.length;++e){const t=T(r[e],s);if(!t)return null;a.includes(t.assetType)&&(o=!0),n.push(t)}return o?n:null}function T(e,t){const s=(0,u.vj)(e,t);return s?{asset:e,assetType:s}:null}async function v(e,t,s){return b(e.map((e=>async function(e,t){const{asset:s,assetType:a}=e;if(s instanceof File)return{blob:s,assetName:s.name,assetType:a};const r=await s.toBlob(t);return(0,o.k_)(t),{blob:r,assetName:s.assetName,assetType:a}}(e,s))),t,s)}async function b(e,t,s){const l=await Promise.all(e.map((async e=>{const a=async function(e,t,s){const{blob:a,assetType:l,assetName:u}=e;let c=null;try{const e=await w({data:a,name:u},t.url,s);(0,o.k_)(s),c={assetType:l,assetUploadId:e.itemID}}catch(e){(0,o.r9)(e),n.Z.getLogger("esri.layers.graphics.sources.support.uploadAssets").warnOnce(`Service ${t.url} does not support the REST Uploads API.`)}if(!c){const e=await(0,i.IR)(a);if((0,o.k_)(s),!e.isBase64)throw new r.Z(`${t.type}-layer:uploadAssets-failure`,"Expected gltf data in base64 format after conversion.",new Error);c={assetType:l,assetData:e.data}}if(!c)throw new r.Z(`${t.type}-layer:uploadAssets-failure`,"Unable to prepare uploadAsset request options.",new Error);return{item:c,assetName:u}}(await e,t,s);return(0,o.k_)(s),a})));(0,o.k_)(s);const{uploadResults:c}=await async function(e,t,s){const n=await(0,a.default)((0,i.v_)(t.parsedUrl.path,"uploadAssets"),{timeout:0,query:{f:"json",assets:JSON.stringify(e)},method:"post",responseType:"json"});if((0,o.k_)(s),n.data.uploadResults.length!==e.length)throw new r.Z(`${t.type}-layer:uploadAssets-failure`,`Bad response. Uploaded ${e.length} items and received ${n.data.uploadResults.length} results.`,new Error);return n.data}(l.map((({item:e})=>e)),t,s);return(0,o.k_)(s),e.map(((e,s)=>function(e,t,s){const{success:a}=t;if(!a){const{error:a}=t;throw new r.Z(`${s.type}-layer:upload-failure`,`Failed to upload mesh file ${e.assetName}. Error code: ${a.code}. Error message: ${a.messages}`,new Error)}const{assetHash:n}=t,{assetName:o,item:{assetType:i}}=e,{infoFor3D:{supportedFormats:l}}=s,c=(0,m.d1)(i,l);if(!c)throw new r.Z(`${s.type}-layer:upload-failure`,`The service allowed us to upload an asset of FormatID ${i}, but it does not list it in its supported formats.`,new Error);return new u.CP(o,c,[new u.LL(`${s.parsedUrl.path}/assets/${n}`,n)])}(l[s],c[s],t)))}async function E(e,t,s){const n=e.map((({assetName:e,parts:t})=>({assetName:e,assetHash:t[0].partHash}))),l=t.capabilities?.operations.supportsAsyncConvert3D,c={query:{f:"json",assets:JSON.stringify(n),transportType:"esriTransportTypeUrl",targetFormat:s,async:l},responseType:"json",timeout:0},p=(0,i.v_)(t.parsedUrl.path,"convert3D"),d=(l?await async function(e,t){const s=(await(0,a.default)(e,t)).data.statusUrl;for(;;){const e=(await(0,a.default)(s,{query:{f:"json"},responseType:"json"})).data;switch(e.status){case"Completed":return(0,a.default)(e.resultUrl,{query:{f:"json"},responseType:"json"});case"CompletedWithErrors":throw new r.Z("async-convert3D-failed","asynchronous convert3D call failed.");case"Failed ImportChanges":case"InProgress":case"Pending":case"ExportAttachments":case"ExportChanges":case"ExportingData":case"ExportingSnapshot":case"ImportAttachments":case"ProvisioningReplica":case"UnRegisteringReplica":break;default:throw new r.Z("async-convert3D-failed","asynchronous convert3D call failed (undefined response status)")}await(0,o.e4)($)}}(p,c):await(0,a.default)(p,c)).data,{infoFor3D:{supportedFormats:f}}=t;return d.assets.map((e=>{const s=(0,m.S0)(e.contentType,f);if(!s)throw new r.Z(`${t.type}-layer:upload-failure`,`The service allowed us to upload an asset of FormatID ${s}, but it does not list it in its supported formats.`,new Error);return new u.CP(e.assetName,e.contentType,[new u.LL(e.assetURL,e.assetHash)])}))}function _(e){const{infoFor3D:t}=e,s=(0,m.S0)("model/gltf-binary",t.supportedFormats)??(0,m.Ow)("glb",t.supportedFormats);if(!s)throw new r.Z(`${e.type}-layer:upload-failure`,"Layer does not support glb.",new Error);return s}const $=1e3}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5234,661],{10661:(e,s,t)=>{t.d(s,{s:()=>o});var n=t(42100);class o extends n.s{notify(){const e=this._observers;if(e&&e.length>0){const s=e.slice();for(const e of s)e.onInvalidated(),e.onCommitted()}}}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6626,3172,5732,661,5234,9880],{99880:(t,e,r)=>{r.d(e,{V:()=>c});var n=r(68773),o=(r(3172),r(20102)),s=r(92604),a=r(81271);const i=s.Z.getLogger("esri.assets");function c(t){if(!n.default.assetsPath)throw i.errorOnce("The API assets location needs to be set using config.assetsPath. More information: https://arcg.is/1OzLe50"),new o.Z("assets:path-not-set","config.assetsPath is not set");return(0,a.v_)(n.default.assetsPath,t)}},5732:(t,e,r)=>{r.d(e,{c:()=>n,g:()=>o});var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function o(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}},46521:(t,e,r)=>{function n(){return[1,0,0,0,1,0,0,0,1]}function o(t,e,r,n,o,s,a,i,c){return[t,e,r,n,o,s,a,i,c]}function s(t,e){return new Float64Array(t,e,9)}r.d(e,{a:()=>s,c:()=>n,f:()=>o}),Object.freeze(Object.defineProperty({__proto__:null,clone:function(t){return[t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8]]},create:n,createView:s,fromValues:o},Symbol.toStringTag,{value:"Module"}))},52138:(t,e,r)=>{r.d(e,{A:()=>p,a:()=>c,d:()=>m,e:()=>f,f:()=>d,g:()=>y,h:()=>x,i:()=>a,j:()=>w,k:()=>h,m:()=>l,s:()=>s,t:()=>i,w:()=>u,y:()=>v,z:()=>_});var n=r(65617),o=r(46851);function s(t,e,r,n,o,s,a,i,c,l,u,h,f,d,m,p,g){return t[0]=e,t[1]=r,t[2]=n,t[3]=o,t[4]=s,t[5]=a,t[6]=i,t[7]=c,t[8]=l,t[9]=u,t[10]=h,t[11]=f,t[12]=d,t[13]=m,t[14]=p,t[15]=g,t}function a(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function i(t,e){if(t===e){const r=e[1],n=e[2],o=e[3],s=e[6],a=e[7],i=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=r,t[6]=e[9],t[7]=e[13],t[8]=n,t[9]=s,t[11]=e[14],t[12]=o,t[13]=a,t[14]=i}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t}function c(t,e){const r=e[0],n=e[1],o=e[2],s=e[3],a=e[4],i=e[5],c=e[6],l=e[7],u=e[8],h=e[9],f=e[10],d=e[11],m=e[12],p=e[13],g=e[14],M=e[15],y=r*i-n*a,b=r*c-o*a,x=r*l-s*a,w=n*c-o*i,_=n*l-s*i,v=o*l-s*c,S=u*p-h*m,q=u*g-f*m,O=u*M-d*m,T=h*g-f*p,B=h*M-d*p,P=f*M-d*g;let E=y*P-b*B+x*T+w*O-_*q+v*S;return E?(E=1/E,t[0]=(i*P-c*B+l*T)*E,t[1]=(o*B-n*P-s*T)*E,t[2]=(p*v-g*_+M*w)*E,t[3]=(f*_-h*v-d*w)*E,t[4]=(c*O-a*P-l*q)*E,t[5]=(r*P-o*O+s*q)*E,t[6]=(g*x-m*v-M*b)*E,t[7]=(u*v-f*x+d*b)*E,t[8]=(a*B-i*O+l*S)*E,t[9]=(n*O-r*B-s*S)*E,t[10]=(m*_-p*x+M*y)*E,t[11]=(h*x-u*_-d*y)*E,t[12]=(i*q-a*T-c*S)*E,t[13]=(r*T-n*q+o*S)*E,t[14]=(p*b-m*w-g*y)*E,t[15]=(u*w-h*b+f*y)*E,t):null}function l(t,e,r){const n=e[0],o=e[1],s=e[2],a=e[3],i=e[4],c=e[5],l=e[6],u=e[7],h=e[8],f=e[9],d=e[10],m=e[11],p=e[12],g=e[13],M=e[14],y=e[15];let b=r[0],x=r[1],w=r[2],_=r[3];return t[0]=b*n+x*i+w*h+_*p,t[1]=b*o+x*c+w*f+_*g,t[2]=b*s+x*l+w*d+_*M,t[3]=b*a+x*u+w*m+_*y,b=r[4],x=r[5],w=r[6],_=r[7],t[4]=b*n+x*i+w*h+_*p,t[5]=b*o+x*c+w*f+_*g,t[6]=b*s+x*l+w*d+_*M,t[7]=b*a+x*u+w*m+_*y,b=r[8],x=r[9],w=r[10],_=r[11],t[8]=b*n+x*i+w*h+_*p,t[9]=b*o+x*c+w*f+_*g,t[10]=b*s+x*l+w*d+_*M,t[11]=b*a+x*u+w*m+_*y,b=r[12],x=r[13],w=r[14],_=r[15],t[12]=b*n+x*i+w*h+_*p,t[13]=b*o+x*c+w*f+_*g,t[14]=b*s+x*l+w*d+_*M,t[15]=b*a+x*u+w*m+_*y,t}function u(t,e,r){const n=r[0],o=r[1],s=r[2];if(e===t)t[12]=e[0]*n+e[4]*o+e[8]*s+e[12],t[13]=e[1]*n+e[5]*o+e[9]*s+e[13],t[14]=e[2]*n+e[6]*o+e[10]*s+e[14],t[15]=e[3]*n+e[7]*o+e[11]*s+e[15];else{const r=e[0],a=e[1],i=e[2],c=e[3],l=e[4],u=e[5],h=e[6],f=e[7],d=e[8],m=e[9],p=e[10],g=e[11];t[0]=r,t[1]=a,t[2]=i,t[3]=c,t[4]=l,t[5]=u,t[6]=h,t[7]=f,t[8]=d,t[9]=m,t[10]=p,t[11]=g,t[12]=r*n+l*o+d*s+e[12],t[13]=a*n+u*o+m*s+e[13],t[14]=i*n+h*o+p*s+e[14],t[15]=c*n+f*o+g*s+e[15]}return t}function h(t,e,r){const n=r[0],o=r[1],s=r[2];return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*o,t[5]=e[5]*o,t[6]=e[6]*o,t[7]=e[7]*o,t[8]=e[8]*s,t[9]=e[9]*s,t[10]=e[10]*s,t[11]=e[11]*s,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function f(t,e,r,n){let s,a,i,c,l,u,h,f,d,m,p,g,M,y,b,x,w,_,v,S,q,O,T,B,P=n[0],E=n[1],k=n[2],C=Math.sqrt(P*P+E*E+k*k);return C<(0,o.g)()?null:(C=1/C,P*=C,E*=C,k*=C,s=Math.sin(r),a=Math.cos(r),i=1-a,c=e[0],l=e[1],u=e[2],h=e[3],f=e[4],d=e[5],m=e[6],p=e[7],g=e[8],M=e[9],y=e[10],b=e[11],x=P*P*i+a,w=E*P*i+k*s,_=k*P*i-E*s,v=P*E*i-k*s,S=E*E*i+a,q=k*E*i+P*s,O=P*k*i+E*s,T=E*k*i-P*s,B=k*k*i+a,t[0]=c*x+f*w+g*_,t[1]=l*x+d*w+M*_,t[2]=u*x+m*w+y*_,t[3]=h*x+p*w+b*_,t[4]=c*v+f*S+g*q,t[5]=l*v+d*S+M*q,t[6]=u*v+m*S+y*q,t[7]=h*v+p*S+b*q,t[8]=c*O+f*T+g*B,t[9]=l*O+d*T+M*B,t[10]=u*O+m*T+y*B,t[11]=h*O+p*T+b*B,e!==t&&(t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t)}function d(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=e[0],t[13]=e[1],t[14]=e[2],t[15]=1,t}function m(t,e,r){if(0===e)return a(t);let n,s,i,c=r[0],l=r[1],u=r[2],h=Math.sqrt(c*c+l*l+u*u);return h<(0,o.g)()?null:(h=1/h,c*=h,l*=h,u*=h,n=Math.sin(e),s=Math.cos(e),i=1-s,t[0]=c*c*i+s,t[1]=l*c*i+u*n,t[2]=u*c*i-l*n,t[3]=0,t[4]=c*l*i-u*n,t[5]=l*l*i+s,t[6]=u*l*i+c*n,t[7]=0,t[8]=c*u*i+l*n,t[9]=l*u*i-c*n,t[10]=u*u*i+s,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t)}function p(t,e){const r=Math.sin(e),n=Math.cos(e);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=n,t[6]=r,t[7]=0,t[8]=0,t[9]=-r,t[10]=n,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function g(t,e,r){const n=e[0],o=e[1],s=e[2],a=e[3],i=n+n,c=o+o,l=s+s,u=n*i,h=n*c,f=n*l,d=o*c,m=o*l,p=s*l,g=a*i,M=a*c,y=a*l;return t[0]=1-(d+p),t[1]=h+y,t[2]=f-M,t[3]=0,t[4]=h-y,t[5]=1-(u+p),t[6]=m+g,t[7]=0,t[8]=f+M,t[9]=m-g,t[10]=1-(u+d),t[11]=0,t[12]=r[0],t[13]=r[1],t[14]=r[2],t[15]=1,t}const M=(0,n.c)();function y(t,e,r,n){const o=e[0],s=e[1],a=e[2],i=e[3],c=o+o,l=s+s,u=a+a,h=o*c,f=o*l,d=o*u,m=s*l,p=s*u,g=a*u,M=i*c,y=i*l,b=i*u,x=n[0],w=n[1],_=n[2];return t[0]=(1-(m+g))*x,t[1]=(f+b)*x,t[2]=(d-y)*x,t[3]=0,t[4]=(f-b)*w,t[5]=(1-(h+g))*w,t[6]=(p+M)*w,t[7]=0,t[8]=(d+y)*_,t[9]=(p-M)*_,t[10]=(1-(h+m))*_,t[11]=0,t[12]=r[0],t[13]=r[1],t[14]=r[2],t[15]=1,t}function b(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t[2]=e[2]-r[2],t[3]=e[3]-r[3],t[4]=e[4]-r[4],t[5]=e[5]-r[5],t[6]=e[6]-r[6],t[7]=e[7]-r[7],t[8]=e[8]-r[8],t[9]=e[9]-r[9],t[10]=e[10]-r[10],t[11]=e[11]-r[11],t[12]=e[12]-r[12],t[13]=e[13]-r[13],t[14]=e[14]-r[14],t[15]=e[15]-r[15],t}function x(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]&&t[4]===e[4]&&t[5]===e[5]&&t[6]===e[6]&&t[7]===e[7]&&t[8]===e[8]&&t[9]===e[9]&&t[10]===e[10]&&t[11]===e[11]&&t[12]===e[12]&&t[13]===e[13]&&t[14]===e[14]&&t[15]===e[15]}function w(t,e){if(t===e)return!0;const r=t[0],n=t[1],s=t[2],a=t[3],i=t[4],c=t[5],l=t[6],u=t[7],h=t[8],f=t[9],d=t[10],m=t[11],p=t[12],g=t[13],M=t[14],y=t[15],b=e[0],x=e[1],w=e[2],_=e[3],v=e[4],S=e[5],q=e[6],O=e[7],T=e[8],B=e[9],P=e[10],E=e[11],k=e[12],C=e[13],A=e[14],j=e[15],Y=(0,o.g)();return Math.abs(r-b)<=Y*Math.max(1,Math.abs(r),Math.abs(b))&&Math.abs(n-x)<=Y*Math.max(1,Math.abs(n),Math.abs(x))&&Math.abs(s-w)<=Y*Math.max(1,Math.abs(s),Math.abs(w))&&Math.abs(a-_)<=Y*Math.max(1,Math.abs(a),Math.abs(_))&&Math.abs(i-v)<=Y*Math.max(1,Math.abs(i),Math.abs(v))&&Math.abs(c-S)<=Y*Math.max(1,Math.abs(c),Math.abs(S))&&Math.abs(l-q)<=Y*Math.max(1,Math.abs(l),Math.abs(q))&&Math.abs(u-O)<=Y*Math.max(1,Math.abs(u),Math.abs(O))&&Math.abs(h-T)<=Y*Math.max(1,Math.abs(h),Math.abs(T))&&Math.abs(f-B)<=Y*Math.max(1,Math.abs(f),Math.abs(B))&&Math.abs(d-P)<=Y*Math.max(1,Math.abs(d),Math.abs(P))&&Math.abs(m-E)<=Y*Math.max(1,Math.abs(m),Math.abs(E))&&Math.abs(p-k)<=Y*Math.max(1,Math.abs(p),Math.abs(k))&&Math.abs(g-C)<=Y*Math.max(1,Math.abs(g),Math.abs(C))&&Math.abs(M-A)<=Y*Math.max(1,Math.abs(M),Math.abs(A))&&Math.abs(y-j)<=Y*Math.max(1,Math.abs(y),Math.abs(j))}function _(t){const e=(0,o.g)(),r=t[0],n=t[1],s=t[2],a=t[4],i=t[5],c=t[6],l=t[8],u=t[9],h=t[10];return Math.abs(1-(r*r+a*a+l*l))<=e&&Math.abs(1-(n*n+i*i+u*u))<=e&&Math.abs(1-(s*s+c*c+h*h))<=e}function v(t){return 1===t[0]&&0===t[1]&&0===t[2]&&0===t[4]&&1===t[5]&&0===t[6]&&0===t[8]&&0===t[9]&&1===t[10]}const S=l,q=b;Object.freeze(Object.defineProperty({__proto__:null,add:function(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t[2]=e[2]+r[2],t[3]=e[3]+r[3],t[4]=e[4]+r[4],t[5]=e[5]+r[5],t[6]=e[6]+r[6],t[7]=e[7]+r[7],t[8]=e[8]+r[8],t[9]=e[9]+r[9],t[10]=e[10]+r[10],t[11]=e[11]+r[11],t[12]=e[12]+r[12],t[13]=e[13]+r[13],t[14]=e[14]+r[14],t[15]=e[15]+r[15],t},adjoint:function(t,e){const r=e[0],n=e[1],o=e[2],s=e[3],a=e[4],i=e[5],c=e[6],l=e[7],u=e[8],h=e[9],f=e[10],d=e[11],m=e[12],p=e[13],g=e[14],M=e[15];return t[0]=i*(f*M-d*g)-h*(c*M-l*g)+p*(c*d-l*f),t[1]=-(n*(f*M-d*g)-h*(o*M-s*g)+p*(o*d-s*f)),t[2]=n*(c*M-l*g)-i*(o*M-s*g)+p*(o*l-s*c),t[3]=-(n*(c*d-l*f)-i*(o*d-s*f)+h*(o*l-s*c)),t[4]=-(a*(f*M-d*g)-u*(c*M-l*g)+m*(c*d-l*f)),t[5]=r*(f*M-d*g)-u*(o*M-s*g)+m*(o*d-s*f),t[6]=-(r*(c*M-l*g)-a*(o*M-s*g)+m*(o*l-s*c)),t[7]=r*(c*d-l*f)-a*(o*d-s*f)+u*(o*l-s*c),t[8]=a*(h*M-d*p)-u*(i*M-l*p)+m*(i*d-l*h),t[9]=-(r*(h*M-d*p)-u*(n*M-s*p)+m*(n*d-s*h)),t[10]=r*(i*M-l*p)-a*(n*M-s*p)+m*(n*l-s*i),t[11]=-(r*(i*d-l*h)-a*(n*d-s*h)+u*(n*l-s*i)),t[12]=-(a*(h*g-f*p)-u*(i*g-c*p)+m*(i*f-c*h)),t[13]=r*(h*g-f*p)-u*(n*g-o*p)+m*(n*f-o*h),t[14]=-(r*(i*g-c*p)-a*(n*g-o*p)+m*(n*c-o*i)),t[15]=r*(i*f-c*h)-a*(n*f-o*h)+u*(n*c-o*i),t},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},determinant:function(t){const e=t[0],r=t[1],n=t[2],o=t[3],s=t[4],a=t[5],i=t[6],c=t[7],l=t[8],u=t[9],h=t[10],f=t[11],d=t[12],m=t[13],p=t[14],g=t[15];return(e*a-r*s)*(h*g-f*p)-(e*i-n*s)*(u*g-f*m)+(e*c-o*s)*(u*p-h*m)+(r*i-n*a)*(l*g-f*d)-(r*c-o*a)*(l*p-h*d)+(n*c-o*i)*(l*m-u*d)},equals:w,exactEquals:x,frob:function(t){return Math.sqrt(t[0]**2+t[1]**2+t[2]**2+t[3]**2+t[4]**2+t[5]**2+t[6]**2+t[7]**2+t[8]**2+t[9]**2+t[10]**2+t[11]**2+t[12]**2+t[13]**2+t[14]**2+t[15]**2)},fromQuat:function(t,e){const r=e[0],n=e[1],o=e[2],s=e[3],a=r+r,i=n+n,c=o+o,l=r*a,u=n*a,h=n*i,f=o*a,d=o*i,m=o*c,p=s*a,g=s*i,M=s*c;return t[0]=1-h-m,t[1]=u+M,t[2]=f-g,t[3]=0,t[4]=u-M,t[5]=1-l-m,t[6]=d+p,t[7]=0,t[8]=f+g,t[9]=d-p,t[10]=1-l-h,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromQuat2:function(t,e){const r=M,n=-e[0],o=-e[1],s=-e[2],a=e[3],i=e[4],c=e[5],l=e[6],u=e[7],h=n*n+o*o+s*s+a*a;return h>0?(r[0]=2*(i*a+u*n+c*s-l*o)/h,r[1]=2*(c*a+u*o+l*n-i*s)/h,r[2]=2*(l*a+u*s+i*o-c*n)/h):(r[0]=2*(i*a+u*n+c*s-l*o),r[1]=2*(c*a+u*o+l*n-i*s),r[2]=2*(l*a+u*s+i*o-c*n)),g(t,e,r),t},fromRotation:m,fromRotationTranslation:g,fromRotationTranslationScale:y,fromRotationTranslationScaleOrigin:function(t,e,r,n,o){const s=e[0],a=e[1],i=e[2],c=e[3],l=s+s,u=a+a,h=i+i,f=s*l,d=s*u,m=s*h,p=a*u,g=a*h,M=i*h,y=c*l,b=c*u,x=c*h,w=n[0],_=n[1],v=n[2],S=o[0],q=o[1],O=o[2],T=(1-(p+M))*w,B=(d+x)*w,P=(m-b)*w,E=(d-x)*_,k=(1-(f+M))*_,C=(g+y)*_,A=(m+b)*v,j=(g-y)*v,Y=(1-(f+p))*v;return t[0]=T,t[1]=B,t[2]=P,t[3]=0,t[4]=E,t[5]=k,t[6]=C,t[7]=0,t[8]=A,t[9]=j,t[10]=Y,t[11]=0,t[12]=r[0]+S-(T*S+E*q+A*O),t[13]=r[1]+q-(B*S+k*q+j*O),t[14]=r[2]+O-(P*S+C*q+Y*O),t[15]=1,t},fromScaling:function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=e[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromTranslation:d,fromXRotation:p,fromYRotation:function(t,e){const r=Math.sin(e),n=Math.cos(e);return t[0]=n,t[1]=0,t[2]=-r,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=r,t[9]=0,t[10]=n,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromZRotation:function(t,e){const r=Math.sin(e),n=Math.cos(e);return t[0]=n,t[1]=r,t[2]=0,t[3]=0,t[4]=-r,t[5]=n,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},frustum:function(t,e,r,n,o,s,a){const i=1/(r-e),c=1/(o-n),l=1/(s-a);return t[0]=2*s*i,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*s*c,t[6]=0,t[7]=0,t[8]=(r+e)*i,t[9]=(o+n)*c,t[10]=(a+s)*l,t[11]=-1,t[12]=0,t[13]=0,t[14]=a*s*2*l,t[15]=0,t},getRotation:function(t,e){const r=e[0]+e[5]+e[10];let n=0;return r>0?(n=2*Math.sqrt(r+1),t[3]=.25*n,t[0]=(e[6]-e[9])/n,t[1]=(e[8]-e[2])/n,t[2]=(e[1]-e[4])/n):e[0]>e[5]&&e[0]>e[10]?(n=2*Math.sqrt(1+e[0]-e[5]-e[10]),t[3]=(e[6]-e[9])/n,t[0]=.25*n,t[1]=(e[1]+e[4])/n,t[2]=(e[8]+e[2])/n):e[5]>e[10]?(n=2*Math.sqrt(1+e[5]-e[0]-e[10]),t[3]=(e[8]-e[2])/n,t[0]=(e[1]+e[4])/n,t[1]=.25*n,t[2]=(e[6]+e[9])/n):(n=2*Math.sqrt(1+e[10]-e[0]-e[5]),t[3]=(e[1]-e[4])/n,t[0]=(e[8]+e[2])/n,t[1]=(e[6]+e[9])/n,t[2]=.25*n),t},getScaling:function(t,e){const r=e[0],n=e[1],o=e[2],s=e[4],a=e[5],i=e[6],c=e[8],l=e[9],u=e[10];return t[0]=Math.sqrt(r*r+n*n+o*o),t[1]=Math.sqrt(s*s+a*a+i*i),t[2]=Math.sqrt(c*c+l*l+u*u),t},getTranslation:function(t,e){return t[0]=e[12],t[1]=e[13],t[2]=e[14],t},hasIdentityRotation:v,identity:a,invert:c,invertOrIdentity:function(t,e){return c(t,e)||a(t),t},isOrthoNormal:_,lookAt:function(t,e,r,n){const s=e[0],i=e[1],c=e[2];let l=s-r[0],u=i-r[1],h=c-r[2];const f=(0,o.g)();if(Math.abs(l)<f&&Math.abs(u)<f&&Math.abs(h)<f)return void a(t);let d=1/Math.sqrt(l*l+u*u+h*h);l*=d,u*=d,h*=d;const m=n[0],p=n[1],g=n[2];let M=p*h-g*u,y=g*l-m*h,b=m*u-p*l;d=Math.sqrt(M*M+y*y+b*b),d?(d=1/d,M*=d,y*=d,b*=d):(M=0,y=0,b=0);let x=u*b-h*y,w=h*M-l*b,_=l*y-u*M;d=Math.sqrt(x*x+w*w+_*_),d?(d=1/d,x*=d,w*=d,_*=d):(x=0,w=0,_=0),t[0]=M,t[1]=x,t[2]=l,t[3]=0,t[4]=y,t[5]=w,t[6]=u,t[7]=0,t[8]=b,t[9]=_,t[10]=h,t[11]=0,t[12]=-(M*s+y*i+b*c),t[13]=-(x*s+w*i+_*c),t[14]=-(l*s+u*i+h*c),t[15]=1},mul:S,multiply:l,multiplyScalar:function(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*r,t[5]=e[5]*r,t[6]=e[6]*r,t[7]=e[7]*r,t[8]=e[8]*r,t[9]=e[9]*r,t[10]=e[10]*r,t[11]=e[11]*r,t[12]=e[12]*r,t[13]=e[13]*r,t[14]=e[14]*r,t[15]=e[15]*r,t},multiplyScalarAndAdd:function(t,e,r,n){return t[0]=e[0]+r[0]*n,t[1]=e[1]+r[1]*n,t[2]=e[2]+r[2]*n,t[3]=e[3]+r[3]*n,t[4]=e[4]+r[4]*n,t[5]=e[5]+r[5]*n,t[6]=e[6]+r[6]*n,t[7]=e[7]+r[7]*n,t[8]=e[8]+r[8]*n,t[9]=e[9]+r[9]*n,t[10]=e[10]+r[10]*n,t[11]=e[11]+r[11]*n,t[12]=e[12]+r[12]*n,t[13]=e[13]+r[13]*n,t[14]=e[14]+r[14]*n,t[15]=e[15]+r[15]*n,t},ortho:function(t,e,r,n,o,s,a){const i=1/(e-r),c=1/(n-o),l=1/(s-a);return t[0]=-2*i,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*c,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*l,t[11]=0,t[12]=(e+r)*i,t[13]=(o+n)*c,t[14]=(a+s)*l,t[15]=1,t},perspective:function(t,e,r,n,o){const s=1/Math.tan(e/2);let a;return t[0]=s/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=s,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=o&&o!==1/0?(a=1/(n-o),t[10]=(o+n)*a,t[14]=2*o*n*a):(t[10]=-1,t[14]=-2*n),t},perspectiveFromFieldOfView:function(t,e,r,n){const o=Math.tan(e.upDegrees*Math.PI/180),s=Math.tan(e.downDegrees*Math.PI/180),a=Math.tan(e.leftDegrees*Math.PI/180),i=Math.tan(e.rightDegrees*Math.PI/180),c=2/(a+i),l=2/(o+s);return t[0]=c,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=l,t[6]=0,t[7]=0,t[8]=-(a-i)*c*.5,t[9]=(o-s)*l*.5,t[10]=n/(r-n),t[11]=-1,t[12]=0,t[13]=0,t[14]=n*r/(r-n),t[15]=0,t},rotate:f,rotateX:function(t,e,r){const n=Math.sin(r),o=Math.cos(r),s=e[4],a=e[5],i=e[6],c=e[7],l=e[8],u=e[9],h=e[10],f=e[11];return e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=s*o+l*n,t[5]=a*o+u*n,t[6]=i*o+h*n,t[7]=c*o+f*n,t[8]=l*o-s*n,t[9]=u*o-a*n,t[10]=h*o-i*n,t[11]=f*o-c*n,t},rotateY:function(t,e,r){const n=Math.sin(r),o=Math.cos(r),s=e[0],a=e[1],i=e[2],c=e[3],l=e[8],u=e[9],h=e[10],f=e[11];return e!==t&&(t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=s*o-l*n,t[1]=a*o-u*n,t[2]=i*o-h*n,t[3]=c*o-f*n,t[8]=s*n+l*o,t[9]=a*n+u*o,t[10]=i*n+h*o,t[11]=c*n+f*o,t},rotateZ:function(t,e,r){const n=Math.sin(r),o=Math.cos(r),s=e[0],a=e[1],i=e[2],c=e[3],l=e[4],u=e[5],h=e[6],f=e[7];return e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=s*o+l*n,t[1]=a*o+u*n,t[2]=i*o+h*n,t[3]=c*o+f*n,t[4]=l*o-s*n,t[5]=u*o-a*n,t[6]=h*o-i*n,t[7]=f*o-c*n,t},scale:h,set:s,str:function(t){return"mat4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+", "+t[9]+", "+t[10]+", "+t[11]+", "+t[12]+", "+t[13]+", "+t[14]+", "+t[15]+")"},sub:q,subtract:b,targetTo:function(t,e,r,n){const o=e[0],s=e[1],a=e[2],i=n[0],c=n[1],l=n[2];let u=o-r[0],h=s-r[1],f=a-r[2],d=u*u+h*h+f*f;d>0&&(d=1/Math.sqrt(d),u*=d,h*=d,f*=d);let m=c*f-l*h,p=l*u-i*f,g=i*h-c*u;return d=m*m+p*p+g*g,d>0&&(d=1/Math.sqrt(d),m*=d,p*=d,g*=d),t[0]=m,t[1]=p,t[2]=g,t[3]=0,t[4]=h*g-f*p,t[5]=f*m-u*g,t[6]=u*p-h*m,t[7]=0,t[8]=u,t[9]=h,t[10]=f,t[11]=0,t[12]=o,t[13]=s,t[14]=a,t[15]=1,t},translate:u,transpose:i},Symbol.toStringTag,{value:"Module"}))},13598:(t,e,r)=>{function n(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function o(t){return[t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15]]}function s(t,e){return new Float64Array(t,e,16)}r.d(e,{I:()=>a,a:()=>s,b:()=>o,c:()=>n});const a=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:o,create:n,createView:s,fromValues:function(t,e,r,n,o,s,a,i,c,l,u,h,f,d,m,p){return[t,e,r,n,o,s,a,i,c,l,u,h,f,d,m,p]}},Symbol.toStringTag,{value:"Module"}))},94961:(t,e,r)=>{function n(){return[0,0,0,1]}function o(t){return[t[0],t[1],t[2],t[3]]}function s(t,e){return new Float64Array(t,e,4)}r.d(e,{I:()=>a,a:()=>n,b:()=>o,c:()=>s});const a=[0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:o,create:n,createView:s,fromValues:function(t,e,r,n){return[t,e,r,n]}},Symbol.toStringTag,{value:"Module"}))},88764:(t,e,r)=>{r.d(e,{q:()=>c});var n,o,s,a=r(5732),i={exports:{}};n=i,o=function(){function t(r,n,o,s,a){for(;s>o;){if(s-o>600){var i=s-o+1,c=n-o+1,l=Math.log(i),u=.5*Math.exp(2*l/3),h=.5*Math.sqrt(l*u*(i-u)/i)*(c-i/2<0?-1:1);t(r,n,Math.max(o,Math.floor(n-c*u/i+h)),Math.min(s,Math.floor(n+(i-c)*u/i+h)),a)}var f=r[n],d=o,m=s;for(e(r,o,n),a(r[s],f)>0&&e(r,o,s);d<m;){for(e(r,d,m),d++,m--;a(r[d],f)<0;)d++;for(;a(r[m],f)>0;)m--}0===a(r[o],f)?e(r,o,m):e(r,++m,s),m<=n&&(o=m+1),n<=m&&(s=m-1)}}function e(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function r(t,e){return t<e?-1:t>e?1:0}return function(e,n,o,s,a){t(e,n,o||0,s||e.length-1,a||r)}},void 0!==(s=o())&&(n.exports=s);const c=(0,a.g)(i.exports)},20773:(t,e,r)=>{r.d(e,{a:()=>i,b:()=>a,c:()=>o,d:()=>u,e:()=>c,n:()=>h,s:()=>l,t:()=>s});var n=r(72220);function o(t,e,r){s(t.typedBuffer,e.typedBuffer,r,t.typedBufferStride,e.typedBufferStride)}function s(t,e,r,o=3,s=o){if(t.length/o!==Math.ceil(e.length/s))return n.c.error("source and destination buffers need to have the same number of elements"),t;const a=t.length/o,i=r[0],c=r[1],l=r[2],u=r[4],h=r[5],f=r[6],d=r[8],m=r[9],p=r[10],g=r[12],M=r[13],y=r[14];let b=0,x=0;for(let r=0;r<a;r++){const r=e[b],n=e[b+1],a=e[b+2];t[x]=i*r+u*n+d*a+g,t[x+1]=c*r+h*n+m*a+M,t[x+2]=l*r+f*n+p*a+y,b+=s,x+=o}return t}function a(t,e,r){i(t.typedBuffer,e.typedBuffer,r,t.typedBufferStride,e.typedBufferStride)}function i(t,e,r,o=3,s=o){if(t.length/o!==Math.ceil(e.length/s))return void n.c.error("source and destination buffers need to have the same number of elements");const a=t.length/o,i=r[0],c=r[1],l=r[2],u=r[3],h=r[4],f=r[5],d=r[6],m=r[7],p=r[8];let g=0,M=0;for(let r=0;r<a;r++){const r=e[g],n=e[g+1],a=e[g+2];t[M]=i*r+u*n+d*a,t[M+1]=c*r+h*n+m*a,t[M+2]=l*r+f*n+p*a,g+=s,M+=o}}function c(t,e,r){l(t.typedBuffer,e,r,t.typedBufferStride)}function l(t,e,r,n=3){const o=Math.min(t.length/n,e.count),s=e.typedBuffer,a=e.typedBufferStride;let i=0,c=0;for(let e=0;e<o;e++)t[c]=r*s[i],t[c+1]=r*s[i+1],t[c+2]=r*s[i+2],i+=a,c+=n}function u(t,e){h(t.typedBuffer,e.typedBuffer,t.typedBufferStride,e.typedBufferStride)}function h(t,e,r=3,n=r){const o=Math.min(t.length/r,e.length/n);let s=0,a=0;for(let i=0;i<o;i++){const o=e[s],i=e[s+1],c=e[s+2],l=o*o+i*i+c*c;if(l>0){const e=1/Math.sqrt(l);t[a]=e*o,t[a+1]=e*i,t[a+2]=e*c}s+=n,a+=r}}Object.freeze(Object.defineProperty({__proto__:null,normalize:h,normalizeView:u,scale:l,scaleView:c,shiftRight:function(t,e,r){const n=Math.min(t.count,e.count),o=t.typedBuffer,s=t.typedBufferStride,a=e.typedBuffer,i=e.typedBufferStride;let c=0,l=0;for(let t=0;t<n;t++)o[l]=a[c]>>r,o[l+1]=a[c+1]>>r,o[l+2]=a[c+2]>>r,c+=i,l+=s},transformMat3:i,transformMat3View:a,transformMat4:s,transformMat4View:o},Symbol.toStringTag,{value:"Module"}))},2368:(t,e,r)=>{r.d(e,{J:()=>u,j:()=>h});var n=r(43697),o=r(92036),s=(r(80442),r(22974)),a=(r(92604),r(70586)),i=r(31263),c=r(1153),l=r(52011);const u=t=>{let e=class extends t{clone(){const t=(0,a.s3)((0,c.vw)(this),"unable to clone instance of non-accessor class"),e=t.metadatas,r=t.store,n={},o=new Map;for(const t in e){const a=e[t],c=r?.originOf(t),l=a.clonable;if(a.readOnly||!1===l||c!==i.s3.USER&&c!==i.s3.DEFAULTS&&c!==i.s3.WEB_MAP&&c!==i.s3.WEB_SCENE)continue;const u=this[t];let h=null;h="function"==typeof l?l(u):"reference"===l?u:(0,s.Vo)(u),null!=u&&null==h||(c===i.s3.DEFAULTS?o.set(t,h):n[t]=h)}const l=new(0,Object.getPrototypeOf(this).constructor)(n);if(o.size){const t=(0,c.vw)(l)?.store;if(t)for(const[e,r]of o)t.set(e,r,i.s3.DEFAULTS)}return l}};return e=(0,n._)([(0,l.j)("esri.core.Clonable")],e),e};let h=class extends(u(o.Z)){};h=(0,n._)([(0,l.j)("esri.core.Clonable")],h)},10661:(t,e,r)=>{r.d(e,{s:()=>o});var n=r(42100);class o extends n.s{notify(){const t=this._observers;if(t&&t.length>0){const e=t.slice();for(const t of e)t.onInvalidated(),t.onCommitted()}}}},24133:(t,e,r)=>{r.d(e,{Q:()=>i});var n=r(67676),o=r(70586),s=r(44553),a=r(88764);class i{constructor(t=9,e){this._compareMinX=h,this._compareMinY=f,this._toBBox=t=>t,this._maxEntries=Math.max(4,t||9),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),e&&("function"==typeof e?this._toBBox=e:this._initFormat(e)),this.clear()}destroy(){this.clear(),x.prune(),w.prune(),_.prune(),v.prune()}all(t){this._all(this._data,t)}search(t,e){let r=this._data;const n=this._toBBox;if(y(t,r))for(x.clear();r;){for(let o=0,s=r.children.length;o<s;o++){const s=r.children[o],a=r.leaf?n(s):s;y(t,a)&&(r.leaf?e(s):M(t,a)?this._all(s,e):x.push(s))}r=x.pop()}}collides(t){let e=this._data;const r=this._toBBox;if(!y(t,e))return!1;for(x.clear();e;){for(let n=0,o=e.children.length;n<o;n++){const o=e.children[n],s=e.leaf?r(o):o;if(y(t,s)){if(e.leaf||M(t,s))return!0;x.push(o)}}e=x.pop()}return!1}load(t){if(!t.length)return this;if(t.length<this._minEntries){for(let e=0,r=t.length;e<r;e++)this.insert(t[e]);return this}let e=this._build(t.slice(0,t.length),0,t.length-1,0);if(this._data.children.length)if(this._data.height===e.height)this._splitRoot(this._data,e);else{if(this._data.height<e.height){const t=this._data;this._data=e,e=t}this._insert(e,this._data.height-e.height-1,!0)}else this._data=e;return this}insert(t){return t&&this._insert(t,this._data.height-1),this}clear(){return this._data=new O([]),this}remove(t){if(!t)return this;let e,r=this._data,s=null,a=0,i=!1;const c=this._toBBox(t);for(_.clear(),v.clear();r||_.length>0;){if(r||(r=(0,o.j0)(_.pop()),s=_.data[_.length-1],a=v.pop()??0,i=!0),r.leaf&&(e=(0,n.cq)(r.children,t,r.children.length,r.indexHint),-1!==e))return r.children.splice(e,1),_.push(r),this._condense(_),this;i||r.leaf||!M(r,c)?s?(a++,r=s.children[a],i=!1):r=null:(_.push(r),v.push(a),a=0,s=r,r=r.children[0])}return this}toJSON(){return this._data}fromJSON(t){return this._data=t,this}_all(t,e){let r=t;for(w.clear();r;){if(!0===r.leaf)for(const t of r.children)e(t);else w.pushArray(r.children);r=w.pop()??null}}_build(t,e,r,n){const o=r-e+1;let s=this._maxEntries;if(o<=s){const n=new O(t.slice(e,r+1));return c(n,this._toBBox),n}n||(n=Math.ceil(Math.log(o)/Math.log(s)),s=Math.ceil(o/s**(n-1)));const a=new T([]);a.height=n;const i=Math.ceil(o/s),l=i*Math.ceil(Math.sqrt(s));b(t,e,r,l,this._compareMinX);for(let o=e;o<=r;o+=l){const e=Math.min(o+l-1,r);b(t,o,e,i,this._compareMinY);for(let r=o;r<=e;r+=i){const o=Math.min(r+i-1,e);a.children.push(this._build(t,r,o,n-1))}}return c(a,this._toBBox),a}_chooseSubtree(t,e,r,n){for(;n.push(e),!0!==e.leaf&&n.length-1!==r;){let r,n=1/0,o=1/0;for(let s=0,a=e.children.length;s<a;s++){const a=e.children[s],i=d(a),c=p(t,a)-i;c<o?(o=c,n=i<n?i:n,r=a):c===o&&i<n&&(n=i,r=a)}e=r||e.children[0]}return e}_insert(t,e,r){const n=this._toBBox,o=r?t:n(t);_.clear();const s=this._chooseSubtree(o,this._data,e,_);for(s.children.push(t),u(s,o);e>=0&&_.data[e].children.length>this._maxEntries;)this._split(_,e),e--;this._adjustParentBBoxes(o,_,e)}_split(t,e){const r=t.data[e],n=r.children.length,o=this._minEntries;this._chooseSplitAxis(r,o,n);const s=this._chooseSplitIndex(r,o,n);if(!s)return void console.log(" Error: assertion failed at PooledRBush._split: no valid split index");const a=r.children.splice(s,r.children.length-s),i=r.leaf?new O(a):new T(a);i.height=r.height,c(r,this._toBBox),c(i,this._toBBox),e?t.data[e-1].children.push(i):this._splitRoot(r,i)}_splitRoot(t,e){this._data=new T([t,e]),this._data.height=t.height+1,c(this._data,this._toBBox)}_chooseSplitIndex(t,e,r){let n,o,s;n=o=1/0;for(let a=e;a<=r-e;a++){const e=l(t,0,a,this._toBBox),i=l(t,a,r,this._toBBox),c=g(e,i),u=d(e)+d(i);c<n?(n=c,s=a,o=u<o?u:o):c===n&&u<o&&(o=u,s=a)}return s}_chooseSplitAxis(t,e,r){const n=t.leaf?this._compareMinX:h,o=t.leaf?this._compareMinY:f;this._allDistMargin(t,e,r,n)<this._allDistMargin(t,e,r,o)&&t.children.sort(n)}_allDistMargin(t,e,r,n){t.children.sort(n);const o=this._toBBox,s=l(t,0,e,o),a=l(t,r-e,r,o);let i=m(s)+m(a);for(let n=e;n<r-e;n++){const e=t.children[n];u(s,t.leaf?o(e):e),i+=m(s)}for(let n=r-e-1;n>=e;n--){const e=t.children[n];u(a,t.leaf?o(e):e),i+=m(a)}return i}_adjustParentBBoxes(t,e,r){for(let n=r;n>=0;n--)u(e.data[n],t)}_condense(t){for(let e=t.length-1;e>=0;e--){const r=t.data[e];if(0===r.children.length)if(e>0){const o=t.data[e-1],s=o.children;s.splice((0,n.cq)(s,r,s.length,o.indexHint),1)}else this.clear();else c(r,this._toBBox)}}_initFormat(t){const e=["return a"," - b",";"];this._compareMinX=new Function("a","b",e.join(t[0])),this._compareMinY=new Function("a","b",e.join(t[1])),this._toBBox=new Function("a","return {minX: a"+t[0]+", minY: a"+t[1]+", maxX: a"+t[2]+", maxY: a"+t[3]+"};")}}function c(t,e){l(t,0,t.children.length,e,t)}function l(t,e,r,n,o){o||(o=new O([])),o.minX=1/0,o.minY=1/0,o.maxX=-1/0,o.maxY=-1/0;for(let s,a=e;a<r;a++)s=t.children[a],u(o,t.leaf?n(s):s);return o}function u(t,e){t.minX=Math.min(t.minX,e.minX),t.minY=Math.min(t.minY,e.minY),t.maxX=Math.max(t.maxX,e.maxX),t.maxY=Math.max(t.maxY,e.maxY)}function h(t,e){return t.minX-e.minX}function f(t,e){return t.minY-e.minY}function d(t){return(t.maxX-t.minX)*(t.maxY-t.minY)}function m(t){return t.maxX-t.minX+(t.maxY-t.minY)}function p(t,e){return(Math.max(e.maxX,t.maxX)-Math.min(e.minX,t.minX))*(Math.max(e.maxY,t.maxY)-Math.min(e.minY,t.minY))}function g(t,e){const r=Math.max(t.minX,e.minX),n=Math.max(t.minY,e.minY),o=Math.min(t.maxX,e.maxX),s=Math.min(t.maxY,e.maxY);return Math.max(0,o-r)*Math.max(0,s-n)}function M(t,e){return t.minX<=e.minX&&t.minY<=e.minY&&e.maxX<=t.maxX&&e.maxY<=t.maxY}function y(t,e){return e.minX<=t.maxX&&e.minY<=t.maxY&&e.maxX>=t.minX&&e.maxY>=t.minY}function b(t,e,r,n,s){const i=[e,r];for(;i.length;){const e=(0,o.j0)(i.pop()),r=(0,o.j0)(i.pop());if(e-r<=n)continue;const c=r+Math.ceil((e-r)/n/2)*n;(0,a.q)(t,c,r,e,s),i.push(r,c,c,e)}}const x=new s.Z,w=new s.Z,_=new s.Z,v=new s.Z({deallocator:void 0});class S{constructor(){this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0}}class q extends S{constructor(){super(...arguments),this.height=1,this.indexHint=new n.SO}}class O extends q{constructor(t){super(),this.children=t,this.leaf=!0}}class T extends q{constructor(t){super(),this.children=t,this.leaf=!1}}},83025:(t,e,r)=>{r.d(e,{JK:()=>i,QZ:()=>s,Rq:()=>a,bg:()=>o,mB:()=>c});var n=r(1533);function o(t,e=!1){return t<=n.DB?e?new Array(t).fill(0):new Array(t):new Float64Array(t)}function s(t){return((0,n.kJ)(t)?t.length:t.byteLength/8)<=n.DB?Array.from(t):new Float64Array(t)}function a(t,e,r){return Array.isArray(t)?t.slice(e,e+r):t.subarray(e,e+r)}function i(t,e){for(let r=0;r<e.length;++r)t[r]=e[r];return t}function c(t){return Array.isArray(t)?new Float64Array(t):t}},85872:(t,e,r)=>{r.d(e,{Z:()=>f});var n=r(43697),o=r(2368),s=r(96674),a=r(5600),i=(r(75215),r(67676),r(80442),r(36030)),c=r(52011),l=r(65617),u=r(94139);let h=class extends((0,o.J)(s.wq)){constructor(t){super(t),this.type="georeferenced-relative",this.isRelative=!0,this.isGeoreferenced=!0,this.origin=(0,l.c)()}getOriginPoint(t){const[e,r,n]=this.origin;return new u.Z({x:e,y:r,z:n,spatialReference:t})}setOriginFormPoint({x:t,y:e,z:r}){this.origin=(0,l.f)(t,e,r??0)}};(0,n._)([(0,i.J)({georeferencedRelative:"georeferenced-relative"},{readOnly:!0})],h.prototype,"type",void 0),(0,n._)([(0,a.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,n._)([(0,c.j)("esri.geometry.support.MeshGeoreferencedRelativeVertexSpace")],h);const f=h},50567:(t,e,r)=>{r.d(e,{Z:()=>l});var n=r(43697),o=r(2368),s=r(96674),a=(r(92604),r(75215),r(67676),r(80442),r(20102),r(36030)),i=r(52011);let c=class extends((0,o.J)(s.wq)){constructor(){super({}),this.type="georeferenced",this.isRelative=!1,this.isGeoreferenced=!0}};(0,n._)([(0,a.J)({georeferenced:"georeferenced"},{readOnly:!0})],c.prototype,"type",void 0),c=(0,n._)([(0,i.j)("esri.geometry.support.MeshGeoreferencedVertexSpace")],c);const l=c},84555:(t,e,r)=>{r.d(e,{Z:()=>f});var n=r(43697),o=r(2368),s=r(96674),a=r(5600),i=(r(75215),r(67676),r(80442),r(36030)),c=r(52011),l=r(65617),u=r(94139);let h=class extends((0,o.J)(s.wq)){constructor(t){super(t),this.type="local",this.isRelative=!0,this.isGeoreferenced=!1,this.origin=(0,l.c)()}getOriginPoint(t){const[e,r,n]=this.origin;return new u.Z({x:e,y:r,z:n,spatialReference:t})}setOriginFormPoint({x:t,y:e,z:r}){this.origin=(0,l.f)(t,e,r??0)}};(0,n._)([(0,i.J)({local:"local"},{readOnly:!0})],h.prototype,"type",void 0),(0,n._)([(0,a.Cb)({type:[Number],nonNullable:!0,json:{write:!0}})],h.prototype,"origin",void 0),h=(0,n._)([(0,c.j)("esri.geometry.support.MeshLocalVertexSpace")],h);const f=h},72220:(t,e,r)=>{r.d(e,{c:()=>n});const n=r(92604).Z.getLogger("esri.views.3d.support.buffer.math")},61787:(t,e,r)=>{r.r(e),r.d(e,{default:()=>a});var n=r(80442),o=r(24133),s=r(66459);class a{async createIndex(t,e){const r=new Array;if(!t.vertexAttributes||!t.vertexAttributes.position)return new o.Q;const n=this._createMeshData(t),s=null!=e?await e.invoke("createIndexThread",n,{transferList:r}):this.createIndexThread(n).result;return this._createPooledRBush().fromJSON(s)}createIndexThread(t){const e=new Float64Array(t.position),r=this._createPooledRBush();return t.components?this._createIndexComponentsThread(r,e,t.components.map((t=>new Uint32Array(t)))):this._createIndexAllThread(r,e)}_createIndexAllThread(t,e){const r=new Array(e.length/9);let n=0;for(let t=0;t<e.length;t+=9)r[n++]=i(e,t,t+3,t+6);return t.load(r),{result:t.toJSON()}}_createIndexComponentsThread(t,e,r){let n=0;for(const t of r)n+=t.length/3;const o=new Array(n);let s=0;for(const t of r)for(let r=0;r<t.length;r+=3)o[s++]=i(e,3*t[r],3*t[r+1],3*t[r+2]);return t.load(o),{result:t.toJSON()}}_createMeshData(t){const e=(t.vertexSpace.isRelative?(0,s.I5)({position:t.vertexAttributes.position,normal:null,tangent:null},t.vertexSpace,t.transform,t.spatialReference).position:t.vertexAttributes.position).buffer;return!t.components||t.components.some((t=>!t.faces))?{position:e}:{position:e,components:t.components.map((t=>t.faces))}}_createPooledRBush(){return new o.Q(9,(0,n.Z)("esri-csp-restrictions")?t=>t:[".minX",".minY",".maxX",".maxY"])}}function i(t,e,r,n){return{minX:Math.min(t[e],t[r],t[n]),maxX:Math.max(t[e],t[r],t[n]),minY:Math.min(t[e+1],t[r+1],t[n+1]),maxY:Math.max(t[e+1],t[r+1],t[n+1]),p0:[t[e],t[e+1],t[e+2]],p1:[t[r],t[r+1],t[r+2]],p2:[t[n],t[n+1],t[n+2]]}}},3172:(t,e,r)=>{r.r(e),r.d(e,{default:()=>d});var n=r(68773),o=r(40330),s=r(20102),a=r(80442),i=r(22974),c=r(95330),l=r(81271),u=r(19745),h=r(71058),f=r(85958);async function d(t,e){t instanceof URL&&(t=t.toString()),e?.query instanceof URLSearchParams&&(e.query=(0,l.u0)(e.query.toString().replaceAll("+"," ")));const i=(0,l.HK)(t),u=(0,l.jc)(t);u||i||(t=(0,l.Fv)(t));const M={url:t,requestOptions:{...e}};let y=(0,l.oh)(t);if(y){const t=await async function(t,e){if(null!=t.responseData)return t.responseData;if(t.headers&&(e.requestOptions.headers={...e.requestOptions.headers,...t.headers}),t.query&&(e.requestOptions.query={...e.requestOptions.query,...t.query}),t.before){let r,n;try{n=await t.before(e)}catch(t){r=v("request:interceptor",t,e)}if((n instanceof Error||n instanceof s.Z)&&(r=v("request:interceptor",n,e)),r)throw t.error&&t.error(r),r;return n}}(y,M);if(null!=t)return{data:t,getHeader:x,httpStatus:200,requestOptions:M.requestOptions,url:M.url};y.after||y.error||(y=null)}if(t=M.url,"image"===(e=M.requestOptions).responseType&&((0,a.Z)("host-webworker")||(0,a.Z)("host-node")))throw v("request:invalid-parameters",new Error("responseType 'image' is not supported in Web Workers or Node environment"),M);if("head"===e.method){if(e.body)throw v("request:invalid-parameters",new Error("body parameter cannot be set when method is 'head'"),M);if(i||u)throw v("request:invalid-parameters",new Error("data and blob URLs are not supported for method 'head'"),M)}if(await async function(){(0,a.Z)("host-webworker")?m||(m=await r.e(9884).then(r.bind(r,29884))):d._abortableFetch||(d._abortableFetch=globalThis.fetch.bind(globalThis))}(),m)return m.execute(t,e);const b=new AbortController;(0,c.fu)(e,(()=>b.abort()));const w={controller:b,credential:void 0,credentialToken:void 0,fetchOptions:void 0,hasToken:!1,interceptor:y,params:M,redoRequest:!1,useIdentity:p.useIdentity,useProxy:!1,useSSL:!1,withCredentials:!1},_=await async function(t){let e,r;await async function(t){const e=t.params.url,r=t.params.requestOptions,s=t.controller.signal,a=r.body;let i=null,l=null;if(g&&"HTMLFormElement"in globalThis&&(a instanceof FormData?i=a:a instanceof HTMLFormElement&&(i=new FormData(a))),"string"==typeof a&&(l=a),t.fetchOptions={cache:r.cacheBust&&!("polyfill"in d._abortableFetch)?"no-cache":"default",credentials:"same-origin",headers:r.headers||{},method:"head"===r.method?"HEAD":"GET",mode:"cors",priority:p.priority,redirect:"follow",signal:s},(i||l)&&(t.fetchOptions.body=i||l),"anonymous"===r.authMode&&(t.useIdentity=!1),t.hasToken=!!(/token=/i.test(e)||r.query?.token||i?.get("token")),!t.hasToken&&n.default.apiKey&&(0,h.r)(e)&&(r.query||(r.query={}),r.query.token=n.default.apiKey,t.hasToken=!0),t.useIdentity&&!t.hasToken&&!t.credentialToken&&!q(e)&&!(0,c.Hc)(s)){let n;"immediate"===r.authMode?(await S(),n=await o.id.getCredential(e,{signal:s}),t.credential=n):"no-prompt"===r.authMode?(await S(),n=await o.id.getCredential(e,{prompt:!1,signal:s}).catch((()=>{})),t.credential=n):o.id&&(n=o.id.findCredential(e)),n&&(t.credentialToken=n.token,t.useSSL=!!n.ssl)}}(t);try{do{[e,r]=await O(t)}while(!await B(t,e,r))}catch(r){const n=v("request:server",r,t.params,e);throw n.details.ssl=t.useSSL,t.interceptor?.error&&t.interceptor.error(n),n}const s=t.params.url;if(r&&/\/sharing\/rest\/(accounts|portals)\/self/i.test(s)){if(!t.hasToken&&!t.credentialToken&&r.user?.username&&!(0,l.kl)(s)){const t=(0,l.P$)(s,!0);t&&p.trustedServers.push(t)}Array.isArray(r.authorizedCrossOriginNoCorsDomains)&&(0,f.Hu)(r.authorizedCrossOriginNoCorsDomains)}const a=t.credential;if(a&&o.id){const t=o.id.findServerInfo(a.server);let e=t?.owningSystemUrl;if(e){e=e.replace(/\/?$/,"/sharing");const t=o.id.findCredential(e,a.userId);t&&-1===o.id._getIdenticalSvcIdx(e,t)&&t.resources.unshift(e)}}return{data:r,getHeader:e?t=>e?.headers.get(t):x,httpStatus:e?.status??200,requestOptions:t.params.requestOptions,ssl:t.useSSL,url:t.params.url}}(w);return y?.after?.(_),_}let m;const p=n.default.request,g="FormData"in globalThis,M=[499,498,403,401],y=["COM_0056","COM_0057","SB_0008"],b=[/\/arcgis\/tokens/i,/\/sharing(\/rest)?\/generatetoken/i,/\/rest\/info/i],x=()=>null,w=Symbol();function _(t){const e=(0,l.P$)(t);return!e||e.endsWith(".arcgis.com")||d._corsServers.includes(e)||(0,l.kl)(e)}function v(t,e,r,n){let o="Error";const a={url:r.url,requestOptions:r.requestOptions,getHeader:x,ssl:!1};if(e instanceof s.Z)return e.details?(e.details=(0,i.d9)(e.details),e.details.url=r.url,e.details.requestOptions=r.requestOptions):e.details=a,e;if(e){const t=n&&(t=>n.headers.get(t)),r=n?.status,s=e.message;s&&(o=s),t&&(a.getHeader=t),a.httpStatus=(null!=e.httpCode?e.httpCode:e.code)||r||0,a.subCode=e.subcode,a.messageCode=e.messageCode,"string"==typeof e.details?a.messages=[e.details]:a.messages=e.details,a.raw=w in e?e[w]:e}return(0,c.D_)(e)?(0,c.zE)():new s.Z(t,o,a)}async function S(){o.id||await Promise.all([r.e(7126),r.e(6261),r.e(9255),r.e(1400),r.e(450)]).then(r.bind(r,73660))}function q(t){return b.some((e=>e.test(t)))}async function O(t){let e=t.params.url;const r=t.params.requestOptions,n=t.fetchOptions??{},s=(0,l.jc)(e)||(0,l.HK)(e),i=r.responseType||"json",h=s?0:null!=r.timeout?r.timeout:p.timeout;let m=!1;if(!s){t.useSSL&&(e=(0,l.hO)(e)),r.cacheBust&&"default"===n.cache&&(e=(0,l.ZN)(e,"request.preventCache",Date.now()));let s={...r.query};t.credentialToken&&(s.token=t.credentialToken);let i=(0,l.B7)(s);(0,a.Z)("esri-url-encodes-apostrophe")&&(i=i.replaceAll("'","%27"));const c=e.length+1+i.length;let h;m="delete"===r.method||"post"===r.method||"put"===r.method||!!r.body||c>p.maxUrlLength;const d=r.useProxy||!!(0,l.ed)(e);if(d){const t=(0,l.b7)(e);h=t.path,!m&&h.length+1+c>p.maxUrlLength&&(m=!0),t.query&&(s={...t.query,...s})}if("HEAD"===n.method&&(m||d)){if(m){if(c>p.maxUrlLength)throw v("request:invalid-parameters",new Error("URL exceeds maximum length"),t.params);throw v("request:invalid-parameters",new Error("cannot use POST request when method is 'head'"),t.params)}if(d)throw v("request:invalid-parameters",new Error("cannot use proxy when method is 'head'"),t.params)}if(m?(n.method="delete"===r.method?"DELETE":"put"===r.method?"PUT":"POST",r.body?e=(0,l.fl)(e,s):(n.body=(0,l.B7)(s),n.headers||(n.headers={}),n.headers["Content-Type"]="application/x-www-form-urlencoded")):e=(0,l.fl)(e,s),d&&(t.useProxy=!0,e=`${h}?${e}`),s.token&&g&&n.body instanceof FormData&&!(0,u.P)(e)&&n.body.set("token",s.token),r.hasOwnProperty("withCredentials"))t.withCredentials=r.withCredentials;else if(!(0,l.D6)(e,(0,l.TI)()))if((0,l.kl)(e))t.withCredentials=!0;else if(o.id){const r=o.id.findServerInfo(e);r?.webTierAuth&&(t.withCredentials=!0)}t.withCredentials&&(n.credentials="include",(0,f.jH)(e)&&await(0,f.jz)(m?(0,l.fl)(e,s):e))}let M,y,b=0,x=!1;h>0&&(b=setTimeout((()=>{x=!0,t.controller.abort()}),h));try{if("native-request-init"===r.responseType)y=n,y.url=e;else if("image"!==r.responseType||"default"!==n.cache||"GET"!==n.method||m||function(t){if(t)for(const e of Object.getOwnPropertyNames(t))if(t[e])return!0;return!1}(r.headers)||!s&&!t.useProxy&&p.proxyUrl&&!_(e)){if(M=await d._abortableFetch(e,n),t.useProxy||function(t){const e=(0,l.P$)(t);e&&!d._corsServers.includes(e)&&d._corsServers.push(e)}(e),"native"===r.responseType)y=M;else if("HEAD"!==n.method)if(M.ok){switch(i){case"array-buffer":y=await M.arrayBuffer();break;case"blob":case"image":y=await M.blob();break;default:y=await M.text()}if(b&&(clearTimeout(b),b=0),"json"===i||"xml"===i||"document"===i)if(y)switch(i){case"json":y=JSON.parse(y);break;case"xml":y=T(y,"application/xml");break;case"document":y=T(y,"text/html")}else y=null;if(y){if("array-buffer"===i||"blob"===i){const t=M.headers.get("Content-Type");if(t&&/application\/json|text\/plain/i.test(t)&&y["blob"===i?"size":"byteLength"]<=750)try{const t=await new Response(y).json();t.error&&(y=t)}catch{}}"image"===i&&y instanceof Blob&&(y=await P(URL.createObjectURL(y),t,!0))}}else{y=await M.text();try{y=JSON.parse(y)}catch{}}}else y=await P(e,t)}catch(n){if("AbortError"===n.name){if(x)throw(0,f.Tf)();throw(0,c.zE)("Request canceled")}if(!(!M&&n instanceof TypeError&&p.proxyUrl)||r.body||"delete"===r.method||"head"===r.method||"post"===r.method||"put"===r.method||t.useProxy||_(e))throw n;t.redoRequest=!0,(0,l.tD)({proxyUrl:p.proxyUrl,urlPrefix:(0,l.P$)(e)??""})}finally{b&&clearTimeout(b)}return[M,y]}function T(t,e){let r;try{r=(new DOMParser).parseFromString(t,e)}catch{}if(!r||r.getElementsByTagName("parsererror").length)throw new SyntaxError("XML Parse error");return r}async function B(t,e,r){if(t.redoRequest)return t.redoRequest=!1,!1;const n=t.params.requestOptions;if(!e||"native"===n.responseType||"native-request-init"===n.responseType)return!0;let s,a;if(r&&(r.error?s=r.error:"error"===r.status&&Array.isArray(r.messages)&&(s={...r},s[w]=r,s.details=r.messages)),!s&&!e.ok)throw s=new Error(`Unable to load ${e.url} status: ${e.status}`),s[w]=r,s;let i,c=null;s&&(a=Number(s.code),c=s.hasOwnProperty("subcode")?Number(s.subcode):null,i=s.messageCode,i=i?.toUpperCase());const l=n.authMode;if(403===a&&(4===c||s.message?.toLowerCase().includes("ssl")&&!s.message.toLowerCase().includes("permission"))){if(!t.useSSL)return t.useSSL=!0,!1}else if(!t.hasToken&&t.useIdentity&&("no-prompt"!==l||498===a)&&void 0!==a&&M.includes(a)&&!q(t.params.url)&&(403!==a||i&&!y.includes(i)&&(null==c||2===c&&t.credentialToken))){await S();try{const e=await o.id.getCredential(t.params.url,{error:v("request:server",s,t.params),prompt:"no-prompt"!==l,signal:t.controller.signal,token:t.credentialToken});return t.credential=e,t.credentialToken=e.token,t.useSSL=t.useSSL||e.ssl,!1}catch(e){if("no-prompt"===l)return t.credential=void 0,t.credentialToken=void 0,!1;s=e}}if(s)throw s;return!0}function P(t,e,r=!1){const n=e.controller.signal,o=new Image;return e.withCredentials?o.crossOrigin="use-credentials":o.crossOrigin="anonymous",o.alt="",o.fetchPriority=p.priority,o.src=t,(0,f.fY)(o,t,r,n)}d._abortableFetch=null,d._corsServers=["https://server.arcgisonline.com","https://services.arcgisonline.com"]},71058:(t,e,r)=>{r.d(e,{r:()=>s});var n=r(81271);const o=["elevation3d.arcgis.com","js.arcgis.com","jsdev.arcgis.com","jsqa.arcgis.com","static.arcgis.com"];function s(t){const e=(0,n.P$)(t,!0);return!!e&&e.endsWith(".arcgis.com")&&!o.includes(e)&&!t.endsWith("/sharing/rest/generateToken")}},85958:(t,e,r)=>{r.d(e,{Hu:()=>h,Tf:()=>u,fY:()=>i,jH:()=>f,jz:()=>d});var n=r(68773),o=r(80442),s=r(95330),a=r(81271);function i(t,e,r=!1,n){return new Promise(((a,i)=>{if((0,s.Hc)(n))return void i(c());let l=()=>{f(),i(new Error(`Unable to load ${e}`))},u=()=>{const e=t;f(),a(e)},h=()=>{if(!t)return;const e=t;f(),e.src="",i(c())};const f=()=>{(0,o.Z)("esri-image-decode")||(t.removeEventListener("error",l),t.removeEventListener("load",u)),l=null,u=null,t=null,null!=n&&n.removeEventListener("abort",h),h=null,r&&URL.revokeObjectURL(e)};null!=n&&n.addEventListener("abort",h),(0,o.Z)("esri-image-decode")?t.decode().then(u,l):(t.addEventListener("error",l),t.addEventListener("load",u))}))}function c(){try{return new DOMException("Aborted","AbortError")}catch{const t=new Error;return t.name="AbortError",t}}const l="Timeout exceeded";function u(){return new Error(l)}function h(t){n.default.request.crossOriginNoCorsDomains||(n.default.request.crossOriginNoCorsDomains={});const e=n.default.request.crossOriginNoCorsDomains;for(let r of t)r=r.toLowerCase(),/^https?:\/\//.test(r)?e[(0,a.P$)(r)??""]=0:(e[(0,a.P$)("http://"+r)??""]=0,e[(0,a.P$)("https://"+r)??""]=0)}function f(t){const e=n.default.request.crossOriginNoCorsDomains;if(e){let r=(0,a.P$)(t);if(r)return r=r.toLowerCase(),!(0,a.D6)(r,(0,a.TI)())&&e[r]<Date.now()-36e5}return!1}async function d(t){const e=n.default.request.crossOriginNoCorsDomains,r=(0,a.P$)(t);e&&r&&(e[r.toLowerCase()]=Date.now());const o=(0,a.mN)(t);t=o.path,"json"===o.query?.f&&(t+="?f=json");try{await fetch(t,{mode:"no-cors",credentials:"include"})}catch{}}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5235],{15235:(e,t,i)=>{i.r(t),i.d(t,{default:()=>R});var r=i(43697),o=i(99880),a=i(40330),s=i(20102),n=i(96674),l=i(22974),p=i(83379),c=i(70586),d=i(81271),u=i(5600),h=i(75215),m=i(71715),g=i(52011),y=i(6570),b=i(48522),v=i(92036),w=i(92604),f=i(90578);i(67676),i(80442);let k=class extends v.Z{constructor(e){super(e),this.portalItem=null}normalizeCtorArgs(e){return e&&e.portalItem&&e.path?{...e,path:this._normalizePath(e.path,e.portalItem)}:e}set path(e){null!=e&&(0,d.YP)(e)?w.Z.getLogger(this).error("portalitemresource:invalid-path","A portal item resource path must be relative"):this._set("path",e)}_castPath(e){return this._normalizePath(e,this.portalItem)}get url(){return this.portalItem&&this.path?`${this.portalItem.itemUrl}/resources/${this.path}`:null}get cdnUrl(){return this.portalItem&&this.path?`${this.portalItem.itemCdnUrl}/resources/${this.path}`:null}get itemRelativeUrl(){return this.portalItem&&this.path?`./resources/${this.path}`:null}fetch(e="json",t){const i=this.cdnUrl;if(null==i)throw new s.Z("portal-item-resource:fetch","Portal item resource does not refer to a valid item or path");return this.portalItem.portal.request(i,{responseType:e,query:{token:this.portalItem.apiKey},signal:t?.signal})}async update(e,t){const{addOrUpdateResource:r}=await i.e(7873).then(i.bind(i,97873));return r(this,"update",e,t)}hasPath(){return null!=this.path}_normalizePath(e,t){return null==e?e:(e=e.replace(/^\/+/,""),null!=t&&(0,d.YP)(e)&&(e=(0,d.PF)(e,t.itemUrl)),e?.replace(/^\/+/,"").replace(/^(\.\/)?resources\//,""))}};(0,r._)([(0,u.Cb)()],k.prototype,"portalItem",void 0),(0,r._)([(0,u.Cb)({type:String,value:null})],k.prototype,"path",null),(0,r._)([(0,f.p)("path")],k.prototype,"_castPath",null),(0,r._)([(0,u.Cb)({type:String,readOnly:!0})],k.prototype,"url",null),(0,r._)([(0,u.Cb)({type:String,readOnly:!0})],k.prototype,"cdnUrl",null),(0,r._)([(0,u.Cb)({type:String,readOnly:!0})],k.prototype,"itemRelativeUrl",null),k=(0,r._)([(0,g.j)("esri.portal.PortalItemResource")],k);const C=k;let S=class extends v.Z{constructor(e){super(e),this.created=null,this.rating=null}};(0,r._)([(0,u.Cb)()],S.prototype,"created",void 0),(0,r._)([(0,u.Cb)()],S.prototype,"rating",void 0),S=(0,r._)([(0,g.j)("esri.portal.PortalRating")],S);const _=S;var I;const x=new Set(["Map Service","Feature Service","Feature Collection","Scene Service","Image Service","Stream Service","Vector Tile Service","GeoJson","CSV","KML","WFS","WMTS","WMS","Feed"]),U=new Set(["KML","GeoJson","CSV"]);let P=I=class extends((0,n.eC)(p.Z)){static from(e){return(0,h.TJ)(I,e)}constructor(e){super(e),this.access=null,this.accessInformation=null,this.apiKey=null,this.applicationProxies=null,this.avgRating=null,this.categories=null,this.created=null,this.culture=null,this.description=null,this.extent=null,this.groupCategories=null,this.id=null,this.isOrgItem=!1,this.itemControl=null,this.licenseInfo=null,this.modified=null,this.name=null,this.numComments=null,this.numRatings=null,this.numViews=null,this.owner=null,this.ownerFolder=null,this.portal=null,this.screenshots=null,this.size=null,this.snippet=null,this.sourceJSON=null,this.sourceUrl=null,this.spatialReference=null,this.tags=null,this.title=null,this.type=null,this.typeKeywords=null,this.url=null}destroy(){this.portal=null}get displayName(){const e=this.type,t=this.typeKeywords||[];let i=e;return"Feature Service"===e||"Feature Collection"===e?i=t.includes("Table")?"Table":t.includes("Route Layer")?"Route Layer":t.includes("Markup")?"Markup":"Feature Layer":"Image Service"===e?i=t.includes("Elevation 3D Layer")?"Elevation Layer":t.includes("Tiled Imagery")?"Tiled Imagery Layer":"Imagery Layer":"Scene Service"===e?i="Scene Layer":"Video Service"===e?i="Video Layer":"Scene Package"===e?i="Scene Layer Package":"Stream Service"===e?i="Feature Layer":"Geoprocessing Service"===e?i=t.includes("Web Tool")?"Tool":"Geoprocessing Service":"Geocoding Service"===e?i="Locator":"Geoenrichment Service"===e?i="GeoEnrichment Service":"Microsoft Powerpoint"===e?i="Microsoft PowerPoint":"GeoJson"===e?i="GeoJSON":"Globe Service"===e?i="Globe Layer":"Vector Tile Service"===e?i="Tile Layer":"netCDF"===e?i="NetCDF":"Map Service"===e?i=t.includes("Spatiotemporal")||!t.includes("Hosted Service")&&!t.includes("Tiled")||t.includes("Relational")?"Map Image Layer":"Tile Layer":e&&e.toLowerCase().includes("add in")?i=e.replaceAll(/(add in)/gi,"Add-In"):"datastore catalog service"===e?i="Big Data File Share":"Compact Tile Package"===e?i="Tile Package (tpkx)":"OGCFeatureServer"===e?i="OGC Feature Layer":"web mapping application"===e&&t.includes("configurableApp")?i="Instant App":"Insights Page"===e?i="Insights Report":"Excalibur Imagery Project"===e&&(i="Excalibur Project"),i}readExtent(e){return e&&e.length?new y.Z(e[0][0],e[0][1],e[1][0],e[1][1]):null}get iconUrl(){const e=this.type&&this.type.toLowerCase()||"",t=this.typeKeywords||[];let i,r=!1,a=!1,s=!1,n=!1,l=!1,p=!1;return e.indexOf("service")>0||"feature collection"===e||"kml"===e||"wms"===e||"wmts"===e||"wfs"===e?(r=t.includes("Hosted Service"),"feature service"===e||"feature collection"===e||"kml"===e||"wfs"===e?(a=t.includes("Table"),s=t.includes("Route Layer"),n=t.includes("Markup"),l=t.includes("Spatiotemporal"),p=t.includes("UtilityNetwork"),i=l&&a?"spatiotemporaltable":a?"table":s?"routelayer":n?"markup":l?"spatiotemporal":r?"featureshosted":p?"utilitynetwork":"features"):i="map service"===e||"wms"===e||"wmts"===e?r||t.includes("Tiled")||"wmts"===e?"maptiles":"mapimages":"scene service"===e?t.includes("Line")?"sceneweblayerline":t.includes("3DObject")?"sceneweblayermultipatch":t.includes("Point")?"sceneweblayerpoint":t.includes("IntegratedMesh")?"sceneweblayermesh":t.includes("PointCloud")?"sceneweblayerpointcloud":t.includes("Polygon")?"sceneweblayerpolygon":t.includes("Building")?"sceneweblayerbuilding":t.includes("Voxel")?"sceneweblayervoxel":"sceneweblayer":"image service"===e?t.includes("Elevation 3D Layer")?"elevationlayer":t.includes("Tiled Imagery")?"tiledimagerylayer":"imagery":"stream service"===e?"streamlayer":"video service"===e?t.includes("Live Stream")?"livestreamvideolayer":"videolayer":"vector tile service"===e?"vectortile":"datastore catalog service"===e?"datastorecollection":"geocoding service"===e?"geocodeservice":"geoprocessing service"===e?t.includes("Web Tool")?"tool":"layers":"geodata service"===e?"geodataservice":"layers"):i="web map"===e||"cityengine web scene"===e?"maps":"web scene"===e?t.includes("ViewingMode-Local")?"webscenelocal":"websceneglobal":"web mapping application"===e&&t.includes("configurableApp")?"instantapps":"web mapping application"===e||"mobile application"===e||"application"===e||"operation view"===e||"desktop application"===e?"apps":"map document"===e||"map package"===e||"published map"===e||"scene document"===e||"globe document"===e||"basemap package"===e||"mobile basemap package"===e||"mobile map package"===e||"project package"===e||"project template"===e||"pro map"===e||"layout"===e||"layer"===e&&t.includes("ArcGIS Pro")||"explorer map"===e&&t.indexOf("Explorer Document")?"mapsgray":"service definition"===e||"csv"===e||"shapefile"===e||"cad drawing"===e||"geojson"===e||"netcdf"===e||"administrative report"===e?"datafiles":"explorer add in"===e||"desktop add in"===e||"windows viewer add in"===e||"windows viewer configuration"===e?"appsgray":"360 vr experience"===e?"360vr":"arcgis pro add in"===e||"arcgis pro configuration"===e?"addindesktop":"rule package"===e||"file geodatabase"===e||"sqlite geodatabase"===e||"csv collection"===e||"kml collection"===e||"windows mobile package"===e||"map template"===e||"desktop application template"===e||"gml"===e||"arcpad package"===e||"code sample"===e||"form"===e||"document link"===e||"earth configuration"===e||"operations dashboard add in"===e||"rules package"===e||"image"===e||"workflow manager package"===e||"explorer map"===e&&t.includes("Explorer Mapping Application")||t.includes("Document")?"datafilesgray":"network analysis service"===e||"geoprocessing service"===e||"geodata service"===e||"geometry service"===e||"geoprocessing package"===e||"locator package"===e||"geoprocessing sample"===e||"workflow manager service"===e?"toolsgray":"layer"===e||"layer package"===e||"explorer layer"===e?"layersgray":"scene package"===e?"scenepackage":"mobile scene package"===e?"mobilescenepackage":"tile package"===e||"compact tile package"===e?"tilepackage":"task file"===e?"taskfile":"report template"===e?"report-template":"statistical data collection"===e?"statisticaldatacollection":"insights workbook"===e?"workbook":"insights model"===e?"insightsmodel":"insights page"===e?"insightspage":"insights theme"===e?"insightstheme":"hub initiative"===e?"hubinitiative":"hubpage"===e?"hubpage":"hub event"===e?"hubevent":"hub site application"===e?"hubsite":"hub project"===e?"hubproject":"relational database connection"===e?"relationaldatabaseconnection":"big data file share"===e?"datastorecollection":"image collection"===e?"imagecollection":"style"===e?"style":"desktop style"===e?"desktopstyle":"dashboard"===e?"dashboard":"raster function template"===e?"rasterprocessingtemplate":"vector tile package"===e?"vectortilepackage":"ortho mapping project"===e?"orthomappingproject":"ortho mapping template"===e?"orthomappingtemplate":"solution"===e?"solutions":"geopackage"===e?"geopackage":"deep learning package"===e?"deeplearningpackage":"real time analytic"===e?"realtimeanalytics":"big data analytic"===e?"bigdataanalytics":"feed"===e?"feed":"excalibur imagery project"===e?"excaliburimageryproject":"notebook"===e?"notebook":"storymap"===e?"storymap":"survey123 add in"===e?"survey123addin":"mission"===e?"mission":"mission report"===e?"missionreport":"quickcapture project"===e?"quickcaptureproject":"pro report"===e?"proreport":"pro report template"===e?"proreporttemplate":"urban model"===e?"urbanmodel":"web experience"===e?"experiencebuilder":"web experience template"===e?"webexperiencetemplate":"experience builder widget"===e?"experiencebuilderwidget":"experience builder widget package"===e?"experiencebuilderwidgetpackage":"workflow"===e?"workflow":"insights script"===e?"insightsscript":"kernel gateway connection"===e?"kernelgatewayconnection":"hub initiative template"===e?"hubinitiativetemplate":"storymap theme"===e?"storymaptheme":"knowledge graph"===e?"knowledgegraph":"native application"===e?"nativeapp":"native application installer"===e?"nativeappinstaller":"link chart"===e?"linkchart":"investigation"===e?"investigation":"ogcfeatureserver"===e?"features":"pro project"===e?"proproject":"insights workbook package"===e?"insightsworkbookpackage":"apache parquet"===e?"apacheparquet":"notebook code snippets"===e||"notebook code snippet library"===e?"notebookcodesnippets":"suitability model"===e?"suitabilitymodel":"esri classifier definition"===e?"classifierdefinition":"esri classification schema"===e?"classificationschema":"insights data engineering workbook"===e?"dataengineeringworkbook":"insights data engineering model"===e?"dataengineeringmodel":"deep learning studio project"===e?"deeplearningproject":"discussion"===e?"discussion":"allsource project"===e?"allsourceproject":"api key"===e?"apikey":"data pipeline"===e?"datapipelines":"maps",i?(0,o.V)("esri/images/portal/"+i+"16.png"):null}get isLayer(){return null!=this.type&&x.has(this.type)}get itemCdnUrl(){let e=this.itemUrl;return e&&a.id&&!a.id.findCredential(e)&&(e=a.id._normalizeAGOLorgDomain(e),e=e.replace(/^https?:\/\/www\.arcgis\.com/,"https://cdn.arcgis.com"),e=e.replace(/^https?:\/\/devext\.arcgis\.com/,"https://cdndev.arcgis.com"),e=e.replace(/^https?:\/\/qaext\.arcgis\.com/,"https://cdnqa.arcgis.com")),e}get itemPageUrl(){const e=this.portal?.itemPageUrl;return e&&this.id?`${e}?id=${this.id}`:null}get itemUrl(){const e=this.portal?.restUrl;return e&&this.id?`${e}/content/items/${this.id}`:null}get thumbnailUrl(){const e=this.itemUrl,t=this.thumbnail;return e&&t?this.portal?.normalizeUrl(`${e}/info/${t}?f=json`)??null:null}get userItemUrl(){const e=this.get("portal.restUrl");if(!e)return null;const t=this.owner||this.get("portal.user.username");return t?`${e}/content/users/${this.ownerFolder?`${t}/${this.ownerFolder}`:t}/items/${this.id}`:null}load(e){const t=this.portal??(this.portal=b.Z.getDefault()),i=t.load(e).then((()=>this.sourceJSON?this.sourceJSON:this.id&&this.itemUrl?t.request(this.itemUrl,{signal:null!=e?e.signal:null,query:{token:this.apiKey}}):{})).then((e=>{this.sourceJSON=e,this.read(e)}));return this.addResolvingPromise(i),Promise.resolve(this)}async addRating(e){const t={method:"post",query:{}};return e instanceof _&&(e=e.rating),null==e||isNaN(e)||"number"!=typeof e||(t.query.rating=e),this.portal?(await this.portal.request(this.itemUrl+"/addRating",t),new _({rating:e,created:new Date})):null}clone(){const e={access:this.access,accessInformation:this.accessInformation,applicationProxies:(0,l.d9)(this.applicationProxies),avgRating:this.avgRating,categories:(0,l.d9)(this.categories),created:(0,l.d9)(this.created),culture:this.culture,description:this.description,extent:(0,l.d9)(this.extent),groupCategories:(0,l.d9)(this.groupCategories),id:this.id,itemControl:this.itemControl,licenseInfo:this.licenseInfo,modified:(0,l.d9)(this.modified),name:this.name,numComments:this.numComments,numRatings:this.numRatings,numViews:this.numViews,owner:this.owner,ownerFolder:this.ownerFolder,portal:this.portal,screenshots:(0,l.d9)(this.screenshots),size:this.size,snippet:this.snippet,sourceUrl:this.sourceUrl,spatialReference:this.spatialReference,tags:(0,l.d9)(this.tags),thumbnail:this.thumbnail,title:this.title,type:this.type,typeKeywords:(0,l.d9)(this.typeKeywords),url:this.url};this.loaded&&(e.loadStatus="loaded");const t=new I({sourceJSON:this.sourceJSON}).set(e);return t._set("isOrgItem",this.isOrgItem),t}createPostQuery(){const e=this.toJSON();for(const t of["tags","typeKeywords","categories"])e[t]=e[t]?.join(", ");const{extent:t}=e;return t&&(e.extent=JSON.stringify(t)),e}async deleteRating(){await(0,c.s3)(this.portal).request(this.itemUrl+"/deleteRating",{method:"post"})}fetchData(e="json",t){return(0,c.s3)(this.portal).request(this.itemUrl+"/data",{responseType:e,...t,query:{token:this.apiKey}})}async fetchRating(e){const t=await(0,c.s3)(this.portal).request(this.itemUrl+"/rating",{query:{token:this.apiKey},...e});return null!=t.rating?(t.created=new Date(t.created),new _(t)):null}fetchRelatedItems(e,t){return(0,c.s3)(this.portal).requestToTypedArray(this.itemUrl+"/relatedItems",{query:{...e,token:this.apiKey},...t},I)}getThumbnailUrl(e){let t=this.thumbnailUrl;return t&&e&&(t+=`&w=${e}`),t}reload(){return(0,c.s3)(this.portal).request(this.itemUrl??"",{cacheBust:!0,query:{token:this.apiKey}}).then((e=>(this.sourceJSON=e,this.read(e),this)))}update(e){return this.id?this.load().then((()=>(0,c.s3)(this.portal).signIn())).then((()=>{const t=e&&e.data,i={method:"post"};i.query=this.createPostQuery();for(const e in i.query)null===i.query[e]&&(i.query[e]="");return i.query.clearEmptyFields=!0,null!=t&&("string"==typeof t?i.query.text=t:"object"==typeof t&&(i.query.text=JSON.stringify(t))),this.portal.request(`${this.userItemUrl}/update`,i).then((()=>this.reload()))})):Promise.reject(new s.Z("portal:item-does-not-exist","The item does not exist yet and cannot be updated"))}async copy(e){if(!this.id)throw new s.Z("portal:item-does-not-exist","The item does not exist yet");await this.load();const{portal:t,itemUrl:i}=this;await(0,c.s3)(t).signIn();const{copyResources:r,folder:o,tags:a,title:n}=e||{},l={method:"post",query:{copyPrivateResources:"all"===r,folder:"string"==typeof o?o:o?.id,includeResources:!!r,tags:a?.join(","),title:n}},{itemId:p}=await t.request(`${i}/copy`,l);return new I({id:p,portal:t})}updateThumbnail(e){return this.id?this.load().then((()=>this.portal.signIn())).then((()=>{const t=e.thumbnail,i=e.filename,r={method:"post"};if("string"==typeof t)(0,d.HK)(t)?r.query={data:t}:r.query={url:(0,d.hF)(t)},null!=i&&(r.query.filename=i);else{const e=new FormData;null!=i?e.append("file",t,i):e.append("file",t),r.body=e}return this.portal.request(`${this.userItemUrl}/updateThumbnail`,r).then((()=>this.reload()))})):Promise.reject(new s.Z("portal:item-does-not-exist","The item does not exist yet and cannot be updated"))}async fetchResources(e={},t){const{fetchResources:r}=await i.e(7873).then(i.bind(i,97873));return r(this,e,t)}async addResource(e,t,r){const{addOrUpdateResource:o}=await i.e(7873).then(i.bind(i,97873));return e.portalItem=this,o(e,"add",t,r)}async removeResource(e,t){const{removeResource:r}=await i.e(7873).then(i.bind(i,97873));if(e.portalItem&&e.portalItem.itemUrl!==this.itemUrl)throw new s.Z("removeresource:portal-item-mismatch","The portal item associated with the provided resource does not match the item");return r(this,e,t)}async removeAllResources(e){const{removeAllResources:t}=await i.e(7873).then(i.bind(i,97873));return t(this,e)}resourceFromPath(e){return new C({portalItem:this,path:e})}toJSON(){const e=this.extent,t={accessInformation:this.accessInformation,categories:(0,l.d9)(this.categories),created:this.created&&this.created.getTime(),description:this.description,extent:e&&[[e.xmin,e.ymin],[e.xmax,e.ymax]],id:this.id,isOrgItem:this.isOrgItem,licenseInfo:this.licenseInfo,modified:this.modified&&this.modified.getTime(),name:this.name,owner:this.owner,ownerFolder:this.ownerFolder,snippet:this.snippet,sourceUrl:this.sourceUrl,spatialReference:this.spatialReference,tags:(0,l.d9)(this.tags),thumbnail:this.thumbnail,title:this.title,type:this.type,typeKeywords:(0,l.d9)(this.typeKeywords),url:this.url};return(0,l.yd)(t)}static fromJSON(e){if(!e)return null;if(e.declaredClass)throw new Error("JSON object is already hydrated");return new I({sourceJSON:e})}_getPostQuery(){const e=this.toJSON();for(const t in e)"tags"===t&&null!==e[t]&&(e[t]=e[t].join(", ")),"typeKeywords"===t&&null!==e[t]&&(e[t]=e[t].join(", ")),"extent"===t&&e[t]&&(e[t]=JSON.stringify(e[t]));return e}};(0,r._)([(0,u.Cb)({type:["private","shared","org","public"]})],P.prototype,"access",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"accessInformation",void 0),(0,r._)([(0,u.Cb)({type:String})],P.prototype,"apiKey",void 0),(0,r._)([(0,u.Cb)({json:{read:{source:"appProxies"}}})],P.prototype,"applicationProxies",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"avgRating",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"categories",void 0),(0,r._)([(0,u.Cb)({type:Date})],P.prototype,"created",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"culture",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"description",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"displayName",null),(0,r._)([(0,u.Cb)({type:y.Z})],P.prototype,"extent",void 0),(0,r._)([(0,m.r)("extent")],P.prototype,"readExtent",null),(0,r._)([(0,u.Cb)()],P.prototype,"groupCategories",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"iconUrl",null),(0,r._)([(0,u.Cb)()],P.prototype,"id",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"isLayer",null),(0,r._)([(0,u.Cb)({type:Boolean,readOnly:!0})],P.prototype,"isOrgItem",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"itemControl",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"itemPageUrl",null),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"itemUrl",null),(0,r._)([(0,u.Cb)()],P.prototype,"licenseInfo",void 0),(0,r._)([(0,u.Cb)({type:Date})],P.prototype,"modified",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"name",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"numComments",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"numRatings",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"numViews",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"owner",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"ownerFolder",void 0),(0,r._)([(0,u.Cb)({type:b.Z})],P.prototype,"portal",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"screenshots",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"size",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"snippet",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"sourceJSON",void 0),(0,r._)([(0,u.Cb)({type:String})],P.prototype,"sourceUrl",void 0),(0,r._)([(0,u.Cb)({type:String})],P.prototype,"spatialReference",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"tags",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"thumbnail",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"thumbnailUrl",null),(0,r._)([(0,u.Cb)()],P.prototype,"title",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"type",void 0),(0,r._)([(0,u.Cb)()],P.prototype,"typeKeywords",void 0),(0,r._)([(0,u.Cb)({type:String,json:{read(e,t){if(U.has(t.type)){const t=this.portal?.restUrl;e||=t&&this.id?`${t}/content/items/${this.id}/data`:null}return e}}})],P.prototype,"url",void 0),(0,r._)([(0,u.Cb)({readOnly:!0})],P.prototype,"userItemUrl",null),P=I=(0,r._)([(0,g.j)("esri.portal.PortalItem")],P);const R=P}}]);
|