@arcgis/core 4.34.0-next.22 → 4.34.0-next.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/applications/Components/arcadeFeatureUtils.d.ts +5 -0
  2. package/applications/Components/arcadeFeatureUtils.js +5 -0
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/0f6203ae32663b2b52db.js +1 -0
  5. package/assets/esri/core/workers/chunks/20bcd2e6cf02e057ad7d.js +1 -0
  6. package/assets/esri/core/workers/chunks/{1d9e44bdd129cc682ae5.js → ac93b3f1ff15a95d926c.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{8b19fe829a9dc26fb3fe.js → d915d0a30d9beb24bd3a.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{bbca1b85656d9ba71e4c.js → def8a854a05f17d3538e.js} +1 -1
  9. package/assets/esri/core/workers/chunks/f90573c9dc36e51cd588.js +1 -0
  10. package/config.js +1 -1
  11. package/interfaces.d.ts +89 -31
  12. package/kernel.js +1 -1
  13. package/layers/VideoLayer.js +1 -1
  14. package/layers/support/SceneModification.js +1 -1
  15. package/layers/support/SceneModifications.js +1 -1
  16. package/layers/support/rasterDatasets/MRFRaster.js +1 -1
  17. package/layers/video/videoUtils.js +1 -1
  18. package/libs/basisu/BasisUEncoder.js +1 -1
  19. package/libs/dxtEncoder/DXTEncoder.js +1 -1
  20. package/libs/i3s/I3SModule.js +1 -1
  21. package/networks/support/utils.js +1 -1
  22. package/package.json +1 -1
  23. package/rest/knowledgeGraph/GraphAddFieldIndexResult.js +1 -1
  24. package/rest/knowledgeGraph/GraphAddNamedTypesResult.js +1 -1
  25. package/rest/knowledgeGraph/GraphAddPropertyResult.js +1 -1
  26. package/rest/knowledgeGraph/GraphDataModelOperationResult.d.ts +1 -1
  27. package/rest/knowledgeGraph/GraphDataModelOperationResult.js +1 -1
  28. package/rest/knowledgeGraph/GraphDeleteFieldIndexResult.js +1 -1
  29. package/rest/knowledgeGraph/GraphDeleteNamedTypeResult.js +1 -1
  30. package/rest/knowledgeGraph/GraphDeletePropertyResult.js +1 -1
  31. package/rest/knowledgeGraph/GraphUpdateNamedTypesResult.js +1 -1
  32. package/rest/knowledgeGraph/GraphUpdatePropertyResult.js +1 -1
  33. package/rest/knowledgeGraph/GraphUpdateSearchIndexResult.js +1 -1
  34. package/support/revision.js +1 -1
  35. package/views/2d/layers/VideoLayerView2D.js +1 -1
  36. package/views/3d/layers/SceneLayerWorker.js +1 -1
  37. package/views/VideoView.js +1 -1
  38. package/views/draw/DrawScreenTool.js +1 -1
  39. package/views/support/TextureCompressionHelper.js +1 -1
  40. package/views/support/TextureCompressionWorker.js +1 -1
  41. package/views/support/TextureCompressionWorkerHandle.js +1 -1
  42. package/widgets/BatchAttributeForm/inputs/EditableInput.js +1 -1
  43. package/widgets/BatchAttributeForm/inputs/GroupInput.js +1 -1
  44. package/widgets/BatchAttributeForm/inputs/InputBase.d.ts +1 -1
  45. package/widgets/BatchAttributeForm/inputs/InputBase.js +1 -1
  46. package/widgets/Feature/FeatureExpression/FeatureExpressionViewModel.js +1 -1
  47. package/widgets/Feature/FeatureViewModel.js +1 -1
  48. package/widgets/Feature/support/arcadeFeatureUtils.js +1 -1
  49. package/widgets/OrientedImageryViewer.js +1 -1
  50. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeature.js +1 -1
  51. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeaturesDrillIn.js +1 -1
  52. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
  53. package/widgets/support/Selector2D/SelectionOperation.js +1 -1
  54. package/widgets/support/UtilityNetworkAssociations/FeatureUtilityNetworkAssociationsViewModel.js +1 -1
  55. package/assets/esri/core/workers/chunks/58e74681ddef30ba9cb6.js +0 -1
  56. package/assets/esri/core/workers/chunks/8fa6c938e8dc7bbfaeb7.js +0 -1
  57. package/assets/esri/core/workers/chunks/e2cb295104ed2f8cd2ff.js +0 -1
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5335,8256],{4146:(e,t,r)=>{r.d(t,{A:()=>_});var i=r(90237),s=r(78888),n=r(49186),o=r(65529),a=r(4902),l=r(92474),u=r(53966),c=r(74887),p=r(84952),d=r(10107),h=(r(44208),r(87811),r(40608)),y=r(5443),f=r(16930),g=r(92602),m=r(64272);let v=0,_=class extends(o.A.EventedMixin(a.A.IdentifiableMixin(l.A))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new y.A(-180,-90,180,90,f.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+v++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=f.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await r.e(7982).then(r.bind(r,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:i}=await r.e(5613).then(r.bind(r,45613));try{return await i(t)}catch(e){const r=t?.portalItem,i=r?.id||"unset",s=r?.portal?.url||g.A.portalUrl;throw u.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+s+"', id: '"+i+"')",e),e}}(e)}initialize(){this.when().catch(e=>{(0,c.zf)(e)||u.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})})}destroy(){const e=this.parent;if(e){const t=this;"layers"in e&&e.layers.includes(t)?e.layers.remove(t):"tables"in e&&e.tables.includes(t)?e.tables.remove(t):"baseLayers"in e&&e.baseLayers.includes(t)?e.baseLayers.remove(t):"referenceLayers"in e&&e.referenceLayers.includes(t)&&e.referenceLayers.remove(t),this._set("parent",null)}}get effectiveVisible(){let e=this.visible;const t=this.parent;return e&&t&&"effectiveVisible"in t&&(e&&=t.effectiveVisible),e}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){return(0,p.An)(this.url)}createLayerView(e,t){return Promise.reject(new n.A("layer:create-layer-view","Layer does not support creating a layer view"))}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,s.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new n.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,i._)([(0,d.MZ)({type:String})],_.prototype,"attributionDataUrl",void 0),(0,i._)([(0,d.MZ)({readOnly:!0})],_.prototype,"effectiveVisible",null),(0,i._)([(0,d.MZ)({type:y.A})],_.prototype,"fullExtent",void 0),(0,i._)([(0,d.MZ)({readOnly:!0})],_.prototype,"hasAttributionData",null),(0,i._)([(0,d.MZ)({type:String,clonable:!1})],_.prototype,"id",void 0),(0,i._)([(0,d.MZ)({type:Boolean,nonNullable:!0})],_.prototype,"legendEnabled",void 0),(0,i._)([(0,d.MZ)({type:["show","hide","hide-children"]})],_.prototype,"listMode",void 0),(0,i._)([(0,d.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],_.prototype,"opacity",void 0),(0,i._)([(0,d.MZ)({clonable:!1})],_.prototype,"parent",void 0),(0,i._)([(0,d.MZ)({readOnly:!0})],_.prototype,"parsedUrl",null),(0,i._)([(0,d.MZ)({type:Boolean,readOnly:!0})],_.prototype,"persistenceEnabled",void 0),(0,i._)([(0,d.MZ)({type:Boolean})],_.prototype,"popupEnabled",void 0),(0,i._)([(0,d.MZ)({type:Boolean})],_.prototype,"attributionVisible",void 0),(0,i._)([(0,d.MZ)({type:f.A})],_.prototype,"spatialReference",void 0),(0,i._)([(0,d.MZ)({type:String})],_.prototype,"title",void 0),(0,i._)([(0,d.MZ)({readOnly:!0,json:{read:!1}})],_.prototype,"type",void 0),(0,i._)([(0,d.MZ)()],_.prototype,"url",void 0),(0,i._)([(0,d.MZ)({type:m.T})],_.prototype,"visibilityTimeExtent",void 0),(0,i._)([(0,d.MZ)({type:Boolean,nonNullable:!0})],_.prototype,"visible",void 0),_=(0,i._)([(0,h.$)("esri.layers.Layer")],_)},4902:(e,t,r)=>{r.d(t,{A:()=>u});var i=r(90237),s=r(40608);let n=0;const o=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+n++})}};return t=(0,i._)([(0,s.$)("esri.core.Identifiable")],t),t};let a=class extends(o(class{})){};var l;a=(0,i._)([(0,s.$)("esri.core.Identifiable")],a),(l=a||(a={})).IdentifiableMixin=o,l.NumericIdentifiableMixin=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:n++})}};return t=(0,i._)([(0,s.$)("esri.core.Identifiable.NumericIdentifiable")],t),t};const u=a},8303:(e,t,r)=>{r.d(t,{A:()=>b});var i=r(90237),s=r(92602),n=r(70333),o=r(78888),a=r(60999),l=r(49186),u=r(53966),c=r(97768),p=r(74887),d=r(84952),h=r(10107),y=(r(44208),r(87811),r(36005)),f=r(40608),g=r(43937),m=r(77548),v=r(20655),_=r(80812),S=r(41318),w=r(10407);const b=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,c.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new _.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:i}=await r.e(1204).then(r.bind(r,41204));return(0,p.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,p.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch(e=>((0,p.QP)(e),!0)))}async setUserPrivileges(e,t){if(!s.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:i},content:{updateItem:s}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",s)}catch(e){(0,p.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const i=!n.id?.findCredential(this.url),s=e===r.id;if(s&&r.portal.user)return this._getUserPrivileges(r,i);let o,a;if(s)o=r.portal.url;else try{o=await(0,m.wI)(this.url,t)}catch(e){(0,p.QP)(e)}if(!o||!(0,d.b8)(o,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;a=await(n.id?.getCredential(`${o}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,p.QP)(e)}const l=!0,u=!1,c=!1;if(!a)return{features:{edit:l,fullEdit:u},content:{updateItem:c}};try{if(s?await r.reload():(r=new _.default({id:e,portal:{url:o}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,i)}catch(e){(0,p.QP)(e)}return{features:{edit:l,fullEdit:u},content:{updateItem:c}}}_getUserPrivileges(e,t){const r=(0,w.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,p.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?n.id?.findCredential(this.url):null;if(!t)return!0;const r=A.credential===t?A.user:await this._fetchEditingUser(e);return A.credential=t,A.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=n.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const i=`${r.owningSystemUrl}/sharing/rest`,s=v.A.getDefault();if(s&&s.loaded&&(0,d.S8)(s.restUrl)===(0,d.S8)(i))return s.user;const l=`${i}/community/self`,u=null!=e?e.signal:null,c=await(0,a.Ke)((0,o.A)(l,{authMode:"no-prompt",query:{f:"json"},signal:u}));return c.ok?S.A.fromJSON(c.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,i=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return r&&i&&!(0,d.ut)(i.restUrl,r.restUrl)?(t.messages&&t.messages.push(new l.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i._)([(0,h.MZ)({type:_.default})],t.prototype,"portalItem",null),(0,i._)([(0,y.w)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,i._)([(0,g.K)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,i._)([(0,h.MZ)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasFullEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasUpdateItemPrivileges",void 0),t=(0,i._)([(0,f.$)("esri.layers.mixins.PortalLayer")],t),t},A={credential:null,user:null}},13069:(e,t,r)=>{r.d(t,{AG:()=>a,lk:()=>s,vD:()=>o,yS:()=>n});const i="randomUUID"in crypto;function s(){if(i)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function n(){return`{${s().toUpperCase()}}`}function o(){return`{${s()}}`}function a(e){const t=e.toUpperCase();return"{"!==e[0]?`{${t}}`:t}},18768:(e,t,r)=>{r.d(t,{b:()=>l});var i=r(90237),s=r(53966),n=r(10107),o=(r(44208),r(87811),r(40608)),a=r(60694);const l=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.qg)(this.url);if(e?.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Jf)(e,s.A.getLogger(this)))}};return(0,i._)([(0,n.MZ)()],t.prototype,"title",null),(0,i._)([(0,n.MZ)({type:String})],t.prototype,"url",null),t=(0,i._)([(0,o.$)("esri.layers.mixins.ArcGISService")],t),t}},25036:(e,t,r)=>{r.d(t,{j:()=>o});var i=r(90237),s=r(10107),n=(r(44208),r(53966),r(87811),r(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;t&&"effectiveScaleRange"in t&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const r=this._get("effectiveScaleRange");return r&&r.minScale===e.minScale&&r.maxScale===e.maxScale?r:e}};return(0,i._)([(0,s.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"minScale",void 0),(0,i._)([(0,s.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"maxScale",void 0),(0,i._)([(0,s.MZ)({readOnly:!0})],t.prototype,"effectiveScaleRange",null),t=(0,i._)([(0,n.$)("esri.layers.mixins.ScaleRangeLayer")],t),t}},52136:(e,t,r)=>{r.d(t,{p:()=>o});var i=r(90237),s=r(10107),n=(r(44208),r(53966),r(87811),r(40608));const o=e=>{let t=class extends e{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,i._)([(0,s.MZ)({type:String})],t.prototype,"apiKey",null),t=(0,i._)([(0,n.$)("esri.layers.mixins.APIKeyMixin")],t),t}},58325:(e,t,r)=>{r.d(t,{A:()=>_});var i,s=r(90237),n=r(78888),o=r(5503),a=r(25482),l=r(84952),u=r(10107),c=(r(44208),r(53966),r(87811),r(40608)),p=r(4718),d=r(67076),h=r(43937),y=r(87024),f=r(39829),g=r(98988);let m=i=class extends a.A{constructor(e){super(e),this.geometry=null,this.type="clip"}writeGeometry(e,t,r,i){if(i.layer?.spatialReference&&!i.layer.spatialReference.equals(this.geometry.spatialReference)){if(!(0,g.canProjectWithoutEngine)(e.spatialReference,i.layer.spatialReference))return void(i?.messages&&i.messages.push(new d.A("scenemodification:unsupported","Scene modifications with incompatible spatial references are not supported",{modification:this,spatialReference:i.layer.spatialReference,context:i})));const s=new f.A;(0,g.projectPolygon)(e,s,i.layer.spatialReference),t[r]=s.toJSON(i)}else t[r]=e.toJSON(i)}clone(){return new i({geometry:(0,p.o8)(this.geometry),type:this.type})}};var v;(0,s._)([(0,u.MZ)({type:f.A}),(0,y.P)()],m.prototype,"geometry",void 0),(0,s._)([(0,h.K)(["web-scene","portal-item"],"geometry")],m.prototype,"writeGeometry",null),(0,s._)([(0,u.MZ)({type:["clip","mask","replace"],nonNullable:!0}),(0,y.P)()],m.prototype,"type",void 0),m=i=(0,s._)([(0,c.$)("esri.layers.support.SceneModification")],m);let _=v=class extends(a.A.JSONSupportMixin(o.A.ofType(m))){constructor(e){super(e),this.url=null}clone(){return new v({url:this.url,items:this.items.map(e=>e.clone())})}toJSON(e){return this.toArray().map(t=>t.toJSON(e)).filter(e=>!!e.geometry)}static fromJSON(e,t){const r=new v;for(const i of e)r.add(m.fromJSON(i,t));return r}static async fromUrl(e,t,r){const i={url:(0,l.An)(e),origin:"service"},s=await(0,n.A)(e,{responseType:"json",signal:r?.signal}),o=t.toJSON(),a=[];for(const e of s.data)a.push(m.fromJSON({...e,geometry:{spatialReference:o,...e.geometry}},i));return new v({url:e,items:a})}};(0,s._)([(0,u.MZ)({type:String})],_.prototype,"url",void 0),_=v=(0,s._)([(0,c.$)("esri.layers.support.SceneModifications")],_)},64272:(e,t,r)=>{r.d(t,{T:()=>d});var i,s=r(90237),n=r(25482),o=r(88930),a=r(10107),l=(r(44208),r(53966),r(87811),r(36005)),u=r(40608),c=r(43937),p=r(98623);let d=class extends n.A{static{i=this}static get allTime(){return h}static get empty(){return y}static fromArray(e){return new i({start:null!=e[0]?new Date(e[0]):e[0],end:null!=e[1]?new Date(e[1]):e[1]})}constructor(e){super(e),this.end=null,this.start=null}readEnd(e,t){return null!=t.end?new Date(t.end):null}writeEnd(e,t){t.end=e?.getTime()??null}get isAllTime(){return this.equals(i.allTime)}get isEmpty(){return this.equals(i.empty)}readStart(e,t){return null!=t.start?new Date(t.start):null}writeStart(e,t){t.start=e?.getTime()??null}clone(){return new i({end:this.end,start:this.start})}equals(e){if(!e)return!1;const t=this.start?.getTime()??this.start,r=this.end?.getTime()??this.end,i=e.start?.getTime()??e.start,s=e.end?.getTime()??e.end;return t===i&&r===s}expandTo(e,t=p.qU){if(this.isEmpty||this.isAllTime)return this.clone();let r=this.start;r&&(r=(0,o.lL)(r,e,t));let s=this.end;if(s){const r=(0,o.lL)(s,e,t);s=s.getTime()===r.getTime()?r:(0,o.S1)(r,1,e,t)}return new i({start:r,end:s})}intersection(e){if(!e)return this.clone();if(this.isEmpty||e.isEmpty)return i.empty;if(this.isAllTime)return e.clone();if(e.isAllTime)return this.clone();const t=this.start?.getTime()??-1/0,r=this.end?.getTime()??1/0,s=e.start?.getTime()??-1/0,n=e.end?.getTime()??1/0;let o,a;return s>=t&&s<=r?o=s:t>=s&&t<=n&&(o=t),r>=s&&r<=n?a=r:n>=t&&n<=r&&(a=n),null==o||null==a||isNaN(o)||isNaN(a)?i.empty:new i({start:o===-1/0?null:new Date(o),end:a===1/0?null:new Date(a)})}offset(e,t,r=p.qU){if(this.isEmpty||this.isAllTime)return this.clone();const s=new i,{start:n,end:a}=this;return null!=n&&(s.start=(0,o.S1)(n,e,t,r)),null!=a&&(s.end=(0,o.S1)(a,e,t,r)),s}toArray(){return this.isEmpty?[void 0,void 0]:[this.start?.getTime()??null,this.end?.getTime()??null]}union(e){if(!e||e.isEmpty)return this.clone();if(this.isEmpty)return e.clone();if(this.isAllTime||e.isAllTime)return h.clone();const t=null!=this.start&&null!=e.start?new Date(Math.min(this.start.getTime(),e.start.getTime())):null,r=null!=this.end&&null!=e.end?new Date(Math.max(this.end.getTime(),e.end.getTime())):null;return new i({start:t,end:r})}};(0,s._)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"end",void 0),(0,s._)([(0,l.w)("end")],d.prototype,"readEnd",null),(0,s._)([(0,c.K)("end")],d.prototype,"writeEnd",null),(0,s._)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isAllTime",null),(0,s._)([(0,a.MZ)({readOnly:!0,json:{read:!1}})],d.prototype,"isEmpty",null),(0,s._)([(0,a.MZ)({type:Date,json:{write:{allowNull:!0}}})],d.prototype,"start",void 0),(0,s._)([(0,l.w)("start")],d.prototype,"readStart",null),(0,s._)([(0,c.K)("start")],d.prototype,"writeStart",null),d=i=(0,s._)([(0,u.$)("esri.time.TimeExtent")],d);const h=new d,y=new d({start:void 0,end:void 0})},69208:(e,t,r)=>{r.d(t,{d:()=>o});var i=r(90237),s=r(10107),n=(r(44208),r(53966),r(87811),r(40608));const o=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,i._)([(0,s.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,i._)([(0,n.$)("esri.layers.mixins.CustomParametersMixin")],t),t}},69540:(e,t,r)=>{r.d(t,{A:()=>d});var i=r(90237),s=r(69622),n=(r(44208),r(4718)),o=(r(53966),r(97768)),a=r(35666),l=r(88620),u=r(40608);const c=e=>{let t=class extends e{clone(e){const t=(0,l.oY)(this);(0,o.Lw)(t,"unable to clone instance of non-accessor class");const r=t.metadata,i=t.store,s={},u=new Map;for(const t in r){const o=r[t],l=i?.originOf(t),c=o.clonable;if(o.readOnly||!1===c||l!==a.Gr.USER&&l!==a.Gr.DEFAULTS&&l!==a.Gr.WEB_MAP&&l!==a.Gr.WEB_SCENE)continue;const p=this[t];let d=null;d="function"==typeof c?c(p,e):"reference"===c?p:(0,n.TU)(p,e),null!=p&&null==d||(l===a.Gr.DEFAULTS?u.set(t,d):s[t]=d)}const c=new(0,Object.getPrototypeOf(this).constructor)(s);if(u.size){const e=(0,l.oY)(c)?.store;if(e)for(const[t,r]of u)e.set(t,r,a.Gr.DEFAULTS)}return c}};return t=(0,i._)([(0,u.$)("esri.core.Clonable")],t),t};let p=class extends(c(s.A)){};p=(0,i._)([(0,u.$)("esri.core.Clonable")],p),(p||(p={})).ClonableMixin=c;const d=p},78553:(e,t,r)=>{r.d(t,{D:()=>n,p:()=>s});var i=r(56507);function s(e){const t=(0,i.Vr)(100*(1-e));return Math.max(0,Math.min(t,100))}function n(e){const t=1-e/100;return Math.max(0,Math.min(t,1))}},80200:(e,t,r)=>{r.d(t,{T:()=>i,d:()=>f});const i={Base64:0,Hex:1,String:2,Raw:3},s=8,n=(1<<s)-1;function o(e,t){const r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function a(e){const t=[];for(let r=0,i=e.length*s;r<i;r+=s)t[r>>5]|=(e.charCodeAt(r/s)&n)<<r%32;return t}function l(e){const t=[];for(let r=0,i=32*e.length;r<i;r+=s)t.push(String.fromCharCode(e[r>>5]>>>r%32&n));return t.join("")}function u(e,t,r,i,s,n){return o(function(e,t){return e<<t|e>>>32-t}(o(o(t,e),o(i,n)),s),r)}function c(e,t,r,i,s,n,o){return u(t&r|~t&i,e,t,s,n,o)}function p(e,t,r,i,s,n,o){return u(t&i|r&~i,e,t,s,n,o)}function d(e,t,r,i,s,n,o){return u(t^r^i,e,t,s,n,o)}function h(e,t,r,i,s,n,o){return u(r^(t|~i),e,t,s,n,o)}function y(e,t){e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;let r=1732584193,i=-271733879,s=-1732584194,n=271733878;for(let t=0;t<e.length;t+=16){const a=r,l=i,u=s,y=n;r=c(r,i,s,n,e[t],7,-680876936),n=c(n,r,i,s,e[t+1],12,-389564586),s=c(s,n,r,i,e[t+2],17,606105819),i=c(i,s,n,r,e[t+3],22,-1044525330),r=c(r,i,s,n,e[t+4],7,-176418897),n=c(n,r,i,s,e[t+5],12,1200080426),s=c(s,n,r,i,e[t+6],17,-1473231341),i=c(i,s,n,r,e[t+7],22,-45705983),r=c(r,i,s,n,e[t+8],7,1770035416),n=c(n,r,i,s,e[t+9],12,-1958414417),s=c(s,n,r,i,e[t+10],17,-42063),i=c(i,s,n,r,e[t+11],22,-1990404162),r=c(r,i,s,n,e[t+12],7,1804603682),n=c(n,r,i,s,e[t+13],12,-40341101),s=c(s,n,r,i,e[t+14],17,-1502002290),i=c(i,s,n,r,e[t+15],22,1236535329),r=p(r,i,s,n,e[t+1],5,-165796510),n=p(n,r,i,s,e[t+6],9,-1069501632),s=p(s,n,r,i,e[t+11],14,643717713),i=p(i,s,n,r,e[t],20,-373897302),r=p(r,i,s,n,e[t+5],5,-701558691),n=p(n,r,i,s,e[t+10],9,38016083),s=p(s,n,r,i,e[t+15],14,-660478335),i=p(i,s,n,r,e[t+4],20,-405537848),r=p(r,i,s,n,e[t+9],5,568446438),n=p(n,r,i,s,e[t+14],9,-1019803690),s=p(s,n,r,i,e[t+3],14,-187363961),i=p(i,s,n,r,e[t+8],20,1163531501),r=p(r,i,s,n,e[t+13],5,-1444681467),n=p(n,r,i,s,e[t+2],9,-51403784),s=p(s,n,r,i,e[t+7],14,1735328473),i=p(i,s,n,r,e[t+12],20,-1926607734),r=d(r,i,s,n,e[t+5],4,-378558),n=d(n,r,i,s,e[t+8],11,-2022574463),s=d(s,n,r,i,e[t+11],16,1839030562),i=d(i,s,n,r,e[t+14],23,-35309556),r=d(r,i,s,n,e[t+1],4,-1530992060),n=d(n,r,i,s,e[t+4],11,1272893353),s=d(s,n,r,i,e[t+7],16,-155497632),i=d(i,s,n,r,e[t+10],23,-1094730640),r=d(r,i,s,n,e[t+13],4,681279174),n=d(n,r,i,s,e[t],11,-358537222),s=d(s,n,r,i,e[t+3],16,-722521979),i=d(i,s,n,r,e[t+6],23,76029189),r=d(r,i,s,n,e[t+9],4,-640364487),n=d(n,r,i,s,e[t+12],11,-421815835),s=d(s,n,r,i,e[t+15],16,530742520),i=d(i,s,n,r,e[t+2],23,-995338651),r=h(r,i,s,n,e[t],6,-198630844),n=h(n,r,i,s,e[t+7],10,1126891415),s=h(s,n,r,i,e[t+14],15,-1416354905),i=h(i,s,n,r,e[t+5],21,-57434055),r=h(r,i,s,n,e[t+12],6,1700485571),n=h(n,r,i,s,e[t+3],10,-1894986606),s=h(s,n,r,i,e[t+10],15,-1051523),i=h(i,s,n,r,e[t+1],21,-2054922799),r=h(r,i,s,n,e[t+8],6,1873313359),n=h(n,r,i,s,e[t+15],10,-30611744),s=h(s,n,r,i,e[t+6],15,-1560198380),i=h(i,s,n,r,e[t+13],21,1309151649),r=h(r,i,s,n,e[t+4],6,-145523070),n=h(n,r,i,s,e[t+11],10,-1120210379),s=h(s,n,r,i,e[t+2],15,718787259),i=h(i,s,n,r,e[t+9],21,-343485551),r=o(r,a),i=o(i,l),s=o(s,u),n=o(n,y)}return[r,i,s,n]}function f(e,t=i.Hex){const r=t||i.Base64,n=y(a(e),e.length*s);switch(r){case i.Raw:return n;case i.Hex:return function(e){const t="0123456789abcdef",r=[];for(let i=0,s=4*e.length;i<s;i++)r.push(t.charAt(e[i>>2]>>i%4*8+4&15)+t.charAt(e[i>>2]>>i%4*8&15));return r.join("")}(n);case i.String:return l(n);case i.Base64:return function(e){const t=[];for(let r=0,i=4*e.length;r<i;r+=3){const i=(e[r>>2]>>r%4*8&255)<<16|(e[r+1>>2]>>(r+1)%4*8&255)<<8|e[r+2>>2]>>(r+2)%4*8&255;for(let s=0;s<4;s++)8*r+6*s>32*e.length?t.push("="):t.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(i>>6*(3-s)&63))}return t.join("")}(n)}}},85648:(e,t,r)=>{r.d(t,{n:()=>s});var i=r(84952);function s(e){return n[function(e){return"json"===e.type?"application/json":"blob"===e.type?e.blob.type:function(e){const t=(0,i.Zo)(e);return l[t]||o}(e.url)}(e)]||a}const n={},o="text/plain",a=n[o],l={png:"image/png",jpeg:"image/jpeg",jpg:"image/jpg",bmp:"image/bmp",gif:"image/gif",json:"application/json",txt:"text/plain",xml:"application/xml",svg:"image/svg+xml",zip:"application/zip",pbf:"application/vnd.mapbox-vector-tile",gz:"application/gzip","bin.gz":"application/octet-stream"};for(const e in l)n[l[e]]=e},87024:(e,t,r)=>{r.d(t,{P:()=>h});var i=r(49186),s=r(80200),n=r(76553),o=r(84952),a=r(13069),l=r(96156),u=r(35666),c=r(10107),p=r(85648),d=r(97159);function h(e){const t=e?.origins??[void 0];return(r,i)=>{const s=function(e,t,r){if("resource"===e?.type)return function(e,t,r){const i=(0,l.z4)(t,r);return{type:String,read:(e,t,r)=>{const s=(0,d.r)(e,t,r);return i.type===String?s:"function"==typeof i.type?new i.type({url:s}):void 0},write:{isRequired:i.json?.write?.isRequired,writer(t,s,a,l){if(!l?.resources)return"string"==typeof t?void(s[a]=(0,d.t)(t,l)):void(s[a]=t.write({},l));const c=function(e){return null==e?null:"string"==typeof e?e:e.url}(t),h=(0,d.t)(c,{...l,verifyItemRelativeUrls:l?.verifyItemRelativeUrls?{writtenUrls:l.verifyItemRelativeUrls.writtenUrls,rootPath:void 0}:void 0},d.M.NO),m=i.type!==String&&(!(0,n.H)(this)||l?.origin&&this.originIdOf(r)>(0,u.aB)(l.origin)),v={object:this,propertyName:r,value:t,targetUrl:h,dest:s,targetPropertyName:a,context:l,params:e};l?.portalItem&&h&&!(0,o.oP)(h)?m&&e?.contentAddressed?y(v):m?function(e){const{context:t,targetUrl:r,params:i,value:s,dest:n,targetPropertyName:a}=e;if(!t.portalItem)return;const l=t.portalItem.resourceFromPath(r),u=g(s,r,t),c=(0,p.n)(u),d=(0,o.Zo)(l.path),h=i?.compress??!1;c===d?(t.resources&&f({...e,resource:l,content:u,compress:h,updates:t.resources.toUpdate}),n[a]=r):y(e)}(v):function({context:e,targetUrl:t,dest:r,targetPropertyName:i}){e.portalItem&&e.resources&&(e.resources.toKeep.push({resource:e.portalItem.resourceFromPath(t),compress:!1}),r[i]=t)}(v):l?.portalItem&&(null==h||null!=(0,d.i)(h)||(0,o.w8)(h)||m)?y(v):s[a]=h}}}}(e,t,r);switch(e?.type??"other"){case"other":return{read:!0,write:!0};case"url":{const{read:e,write:t}=d.b;return{read:e,write:t}}}}(e,r,i);for(const e of t){const t=(0,c.rM)(r,e,i);for(const e in s)t[e]=s[e]}}}function y(e){const{targetUrl:t,params:r,value:n,context:l,dest:u,targetPropertyName:c}=e;if(!l.portalItem)return;const h=(0,d.p)(t),y=g(n,t,l);if(r?.contentAddressed&&"json"!==y.type)return void l.messages?.push(new i.A("persistable:contentAddressingUnsupported",`Property "${c}" is trying to serializing a resource with content of type ${y.type} with content addressing. Content addressing is only supported for json resources.`,{content:y}));const m=r?.contentAddressed&&"json"===y.type?(0,s.d)(y.jsonString):h?.filename??(0,a.lk)(),v=(0,o.fj)(r?.prefix??h?.prefix,m),_=`${v}.${(0,p.n)(y)}`;if(r?.contentAddressed&&l.resources&&"json"===y.type){const e=l.resources.toKeep.find(({resource:e})=>e.path===_)??l.resources.toAdd.find(({resource:e})=>e.path===_);if(e)return void(u[c]=e.resource.itemRelativeUrl)}const S=l.portalItem.resourceFromPath(_);(0,o.w8)(t)&&l.resources&&l.resources.pendingOperations.push((0,o.tk)(t).then(e=>{S.path=`${v}.${(0,p.n)({type:"blob",blob:e})}`,u[c]=S.itemRelativeUrl}).catch(()=>{}));const w=r?.compress??!1;l.resources&&f({...e,resource:S,content:y,compress:w,updates:l.resources.toAdd}),u[c]=S.itemRelativeUrl}function f({object:e,propertyName:t,updates:r,resource:i,content:s,compress:n}){r.push({resource:i,content:s,compress:n,finish:r=>{!function(e,t,r){"string"==typeof e[t]?e[t]=r.url:e[t].url=r.url}(e,t,r)}})}function g(e,t,r){return"string"==typeof e?{type:"url",url:t}:{type:"json",jsonString:JSON.stringify(e.toJSON(r))}}},92071:(e,t,r)=>{r.d(t,{P:()=>_,L:()=>S});var i=r(90237),s=r(69622),n=r(76953),o=r(4718),a=r(35666);class l{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(a.AU),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new l,r=this._originStores[a.Gr.DEFAULTS];r&&r.forEach((e,r)=>{t.set(r,(0,o.o8)(e),a.Gr.DEFAULTS)});for(let r=a.Gr.SERVICE;r<a.AU;r++){const i=this._originStores[r];i&&i.forEach((i,s)=>{e&&e.has(s)||t.set(s,(0,o.o8)(i),r)})}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=a.Gr.USER){let i=this._originStores[r];if(i||(i=new Map,this._originStores[r]=i),i.set(e,t),!this._values.has(e)||this._propertyOriginMap.get(e)<=r){const i=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),i!==t}return!1}delete(e,t=a.Gr.USER){const r=this._originStores[t];if(!r)return;const i=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return i}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],i=r?.get(e),s=this._values.get(e);return this._values.set(e,i),this._propertyOriginMap.set(e,t),s!==i}originOf(e){return this._propertyOriginMap.get(e)||a.Gr.DEFAULTS}isAtOrigin(e,t){return this.has(e,t)&&this.originOf(e)===t}isBelowOrigin(e,t){return!this.has(e)||this.originOf(e)<t}forEach(e){this._values.forEach(e)}}var u=r(45917),c=r(88620),p=r(40608);const d=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,c.oY)(this),r=t.store,i=new l;t.store=i,(0,n.k)(t,r,i)}read(e,t){(0,u.L)(this,e,t)}getAtOrigin(e,t){const r=h(this),i=(0,a.aB)(t);if("string"==typeof e)return r.get(e,i);const s={};return e.forEach(e=>{s[e]=r.get(e,i)}),s}originOf(e){return(0,a.OL)(this.originIdOf(e))}originIdOf(e){return h(this).originOf(e)}revert(e,t){const r=h(this),i=(0,a.aB)(t),s=(0,c.oY)(this);let n;n="string"==typeof e?"*"===e?r.keys(i):[e]:e,n.forEach(e=>{s.invalidate(e),r.revert(e,i),s.commit(e)})}};return t=(0,i._)([(0,p.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function h(e){return(0,c.oY)(e).store}let y=class extends(d(s.A)){};y=(0,i._)([(0,p.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],y);var f=r(16649),g=r(49422);const m=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){(0,c.oY)(this).clearOrigin(e,(0,a.aB)(t))}write(e,t){return(0,g.M)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,c.oY)(this).setAtOrigin(e,t,(0,a.aB)(r))}removeOrigin(e){const t=v(this),r=(0,a.aB)(e),i=t.keys(r);for(const e of i)t.originOf(e)===r&&t.set(e,t.get(e,r),a.Gr.USER)}updateOrigin(e,t){const r=v(this),i=(0,a.aB)(t),s=(0,f.Jt)(this,e);for(let t=i+1;t<a.AU;++t)r.delete(e,t);r.set(e,s,i)}toJSON(e){return this.write({},e)}};return t=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function v(e){return(0,c.oY)(e).store}const _=e=>{let t=class extends(m(d(e))){constructor(...e){super(...e)}};return t=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport")],t),t};let S=class extends(_(s.A)){};S=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport")],S)}}]);
package/config.js CHANGED
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import"./core/has.js";import{deepMerge as e}from"./core/object.js";const s={apiKey:void 0,apiKeys:{scopes:[]},applicationName:"",applicationUrl:globalThis.location?.href,assetsPath:"",fontsUrl:"https://static.arcgis.com/fonts",geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",userPrivilegesApplied:!0,portalUrl:"https://www.arcgis.com",respectPrefersReducedMotion:!0,routeServiceUrl:"https://route-api.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{crossOriginNoCorsDomains:null,httpsDomains:["arcgis.com","arcgisonline.com","esrikr.com","premiumservices.blackbridge.com","esripremium.accuweather.com","gbm.digitalglobe.com","firstlook.digitalglobe.com","msi.digitalglobe.com"],interceptors:[],internalInterceptors:[],maxUrlLength:2e3,priority:"high",proxyRules:[],proxyUrl:null,timeout:62e3,trustedServers:[],useIdentity:!0},log:{interceptors:[],level:null}};if(globalThis.esriConfig&&(e(s,globalThis.esriConfig,!0),delete s.has),!s.assetsPath){{const e="4.34.0-next.22";s.assetsPath=`https://cdn.jsdelivr.net/npm/@arcgis/core@${e}/assets`}s.defaultAssetsPath=s.assetsPath}export{s as default};
5
+ import"./core/has.js";import{deepMerge as e}from"./core/object.js";const s={apiKey:void 0,apiKeys:{scopes:[]},applicationName:"",applicationUrl:globalThis.location?.href,assetsPath:"",fontsUrl:"https://static.arcgis.com/fonts",geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",userPrivilegesApplied:!0,portalUrl:"https://www.arcgis.com",respectPrefersReducedMotion:!0,routeServiceUrl:"https://route-api.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{crossOriginNoCorsDomains:null,httpsDomains:["arcgis.com","arcgisonline.com","esrikr.com","premiumservices.blackbridge.com","esripremium.accuweather.com","gbm.digitalglobe.com","firstlook.digitalglobe.com","msi.digitalglobe.com"],interceptors:[],internalInterceptors:[],maxUrlLength:2e3,priority:"high",proxyRules:[],proxyUrl:null,timeout:62e3,trustedServers:[],useIdentity:!0},log:{interceptors:[],level:null}};if(globalThis.esriConfig&&(e(s,globalThis.esriConfig,!0),delete s.has),!s.assetsPath){{const e="4.34.0-next.23";s.assetsPath=`https://cdn.jsdelivr.net/npm/@arcgis/core@${e}/assets`}s.defaultAssetsPath=s.assetsPath}export{s as default};
package/interfaces.d.ts CHANGED
@@ -233,9 +233,11 @@ declare namespace __esri {
233
233
  export type BaseTileLayerLayerviewDestroyEventHandler = (event: BaseTileLayerLayerviewDestroyEvent) => void;
234
234
  export type BaseTileLayerRefreshEventHandler = (event: BaseTileLayerRefreshEvent) => void;
235
235
  export type BatchAttributeFormSubmitEventHandler = (event: BatchAttributeFormSubmitEvent) => void;
236
- export type BatchAttributeFormValueChangeEvent1Handler = (event: BatchAttributeFormValueChangeEvent1) => void;
237
236
  export type BatchAttributeFormValueChangeEventHandler = (event: BatchAttributeFormValueChangeEvent) => void;
238
237
  export type BatchAttributeFormViewModelSubmitEventHandler = (event: BatchAttributeFormViewModelSubmitEvent) => void;
238
+ export type BatchAttributeFormViewModelValueChangeEventHandler = (
239
+ event: BatchAttributeFormViewModelValueChangeEvent,
240
+ ) => void;
239
241
  export type BingMapsLayerLayerviewCreateErrorEventHandler = (event: BingMapsLayerLayerviewCreateErrorEvent) => void;
240
242
  export type BingMapsLayerLayerviewCreateEventHandler = (event: BingMapsLayerLayerviewCreateEvent) => void;
241
243
  export type BingMapsLayerLayerviewDestroyEventHandler = (event: BingMapsLayerLayerviewDestroyEvent) => void;
@@ -256,6 +258,7 @@ declare namespace __esri {
256
258
  export type CSVLayerLayerviewCreateEventHandler = (event: CSVLayerLayerviewCreateEvent) => void;
257
259
  export type CSVLayerLayerviewDestroyEventHandler = (event: CSVLayerLayerviewDestroyEvent) => void;
258
260
  export type CSVLayerRefreshEventHandler = (event: CSVLayerRefreshEvent) => void;
261
+ export type DaylightUserDateTimeChangeEventHandler = (event: DaylightUserDateTimeChangeEvent) => void;
259
262
  export type DaylightViewModelUserDateTimeChangeEventHandler = (
260
263
  event: DaylightViewModelUserDateTimeChangeEvent,
261
264
  ) => void;
@@ -1354,6 +1357,48 @@ declare namespace __esri {
1354
1357
 
1355
1358
  export const analysisUtils: analysisUtils;
1356
1359
 
1360
+ /**
1361
+ * Note: reserved for internal use only, this is not part of the stable public API.
1362
+ *
1363
+ * Arcade feature utils for Components.
1364
+ */
1365
+ interface arcadeFeatureUtils {
1366
+ /**
1367
+ * Note: reserved for internal use only, this is not part of the stable public API.
1368
+ *
1369
+ * Compiles an Arcade expression info object into a compiled expression info.
1370
+ *
1371
+ * @param params The parameters for compilation.
1372
+ */
1373
+ compileExpression(params: arcadeFeatureUtilsCompileExpressionParams): Promise<any | nullish>;
1374
+ /**
1375
+ * Note: reserved for internal use only, this is not part of the stable public API.
1376
+ *
1377
+ * Compiles an array of Arcade expression info objects into compiled expression infos.
1378
+ *
1379
+ * @param expressionInfos Array of Arcade expression info objects.
1380
+ * @param graphic The graphic to use for context.
1381
+ */
1382
+ compileExpressionInfos(expressionInfos: popupExpressionInfo[], graphic: Graphic): Promise<any>;
1383
+ /**
1384
+ * Note: reserved for internal use only, this is not part of the stable public API.
1385
+ *
1386
+ * Formats a value returned from an Arcade expression for display.
1387
+ *
1388
+ * @param value The value to format.
1389
+ */
1390
+ formatArcadeValue(value: string): string;
1391
+ }
1392
+
1393
+ export const arcadeFeatureUtils: arcadeFeatureUtils;
1394
+
1395
+ export interface arcadeFeatureUtilsCompileExpressionParams {
1396
+ expressionInfo: popupExpressionInfo;
1397
+ createArcadeExecutor: any;
1398
+ createArcadeProfile: any;
1399
+ graphic: Graphic;
1400
+ }
1401
+
1357
1402
  /**
1358
1403
  * Note: reserved for internal use only, this is not part of the stable public API.
1359
1404
  *
@@ -1827,10 +1872,12 @@ declare namespace __esri {
1827
1872
  focused: boolean;
1828
1873
  height: number;
1829
1874
  layer: VideoLayer | nullish;
1875
+ map: Map | WebMap | nullish;
1830
1876
  ready: boolean;
1831
1877
  resizing: boolean;
1832
1878
  videoSize: number[];
1833
1879
  width: number;
1880
+ operationalDataVisible: boolean;
1834
1881
  }
1835
1882
 
1836
1883
  /**
@@ -5046,7 +5093,7 @@ declare namespace __esri {
5046
5093
 
5047
5094
  /**
5048
5095
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-form-elements-Element.html Element} classes
5049
- * when developing with {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
5096
+ * when developing with {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
5050
5097
  *
5051
5098
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-form-elements.html Read more...}
5052
5099
  */
@@ -5572,7 +5619,7 @@ declare namespace __esri {
5572
5619
 
5573
5620
  /**
5574
5621
  * A convenience module for importing module:esri/form/elements/inputs/Input classes
5575
- * when developing with {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
5622
+ * when developing with {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
5576
5623
  *
5577
5624
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-form-elements-inputs.html Read more...}
5578
5625
  */
@@ -7356,7 +7403,7 @@ declare namespace __esri {
7356
7403
 
7357
7404
  /**
7358
7405
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Geometry.html Geometry} classes when developing with
7359
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
7406
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
7360
7407
  *
7361
7408
  * @deprecated since version 4.32. Use {@link module:esri/unionTypes} to import union types, or individual modules to import classes.
7362
7409
  *
@@ -24657,7 +24704,8 @@ declare namespace __esri {
24657
24704
  readonly spatialReference: SpatialReference;
24658
24705
  readonly type: "line-of-sight";
24659
24706
  /**
24660
- * LineOfSightLayer computes the line of sight from a single observer position towards
24707
+ * The line of sight layer enables the creation and display of visibility analysis where a line of sight
24708
+ * is computed from a single observer position towards
24661
24709
  * a set of targets.
24662
24710
  *
24663
24711
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-LineOfSightLayer.html Read more...}
@@ -50014,7 +50062,7 @@ declare namespace __esri {
50014
50062
 
50015
50063
  /**
50016
50064
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-PointCloudRenderer.html PointCloudRenderer} classes when developing with
50017
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
50065
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
50018
50066
  *
50019
50067
  * @deprecated since version 4.32. Use {@link module:esri/unionTypes} to import union types, or individual modules to import classes.
50020
50068
  *
@@ -50116,7 +50164,7 @@ declare namespace __esri {
50116
50164
 
50117
50165
  /**
50118
50166
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-popup-content-Content.html Content} classes when developing
50119
- * with {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
50167
+ * with {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
50120
50168
  *
50121
50169
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-popup-content.html Read more...}
50122
50170
  */
@@ -55524,7 +55572,7 @@ declare namespace __esri {
55524
55572
  /**
55525
55573
  * A convenience module for importing renderer classes that can be used to render
55526
55574
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-ImageryLayer.html ImageryLayer} when developing with
55527
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
55575
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
55528
55576
  *
55529
55577
  * @deprecated since version 4.32. Use {@link module:esri/unionTypes} to import union types, or individual modules to import classes.
55530
55578
  *
@@ -55655,7 +55703,7 @@ declare namespace __esri {
55655
55703
 
55656
55704
  /**
55657
55705
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-renderers-Renderer.html Renderer} classes when developing with
55658
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
55706
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
55659
55707
  *
55660
55708
  * @deprecated since version 4.32. Use {@link module:esri/unionTypes} to import union types, or individual modules to import classes.
55661
55709
  *
@@ -64588,7 +64636,7 @@ declare namespace __esri {
64588
64636
 
64589
64637
  /**
64590
64638
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-rest-locator.html locator} functions when developing with
64591
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
64639
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
64592
64640
  *
64593
64641
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-rest-locator.html Read more...}
64594
64642
  */
@@ -85895,7 +85943,7 @@ declare namespace __esri {
85895
85943
 
85896
85944
  /**
85897
85945
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-symbols-Symbol.html Symbol} classes when developing with
85898
- * {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
85946
+ * {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
85899
85947
  *
85900
85948
  * @deprecated since version 4.32. Use {@link module:esri/unionTypes} to import union types, or individual modules to import classes.
85901
85949
  *
@@ -91110,7 +91158,7 @@ declare namespace __esri {
91110
91158
 
91111
91159
  /**
91112
91160
  * A convenience module for importing {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-tables-elements-AttributeTableElement.html AttributeTableElement} classes
91113
- * when developing with {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
91161
+ * when developing with {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
91114
91162
  *
91115
91163
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-tables-elements.html Read more...}
91116
91164
  */
@@ -91777,7 +91825,7 @@ declare namespace __esri {
91777
91825
  }
91778
91826
 
91779
91827
  /**
91780
- * A module for importing union types for use in {@link https://developers.arcgis.com/javascript/latest/typescript-setup/ TypeScript}.
91828
+ * A module for importing union types for use in {@link https://developers.arcgis.com/javascript/latest/get-started/#typescript TypeScript}.
91781
91829
  *
91782
91830
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-unionTypes.html Read more...}
91783
91831
  */
@@ -93047,7 +93095,7 @@ declare namespace __esri {
93047
93095
  /**
93048
93096
  * Tessellate a {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Polygon.html Polygon} into triangles.
93049
93097
  *
93050
- * @param polygon The input geometry. *The geometry must be simple*; if the input geometry is not simple, you must first create a simplified version of it using {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-geometryEngine.html#simplify geometryEngine.simplify}, and pass the simplified geometry to `tessellatePolygon`.
93098
+ * @param polygon The input geometry. *The geometry must be simple*; if the input geometry is not simple, you must first create a simplified version of it using {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-simplifyOperator.html simplifyOperator}, and pass the simplified geometry to `tessellatePolygon`.
93051
93099
  *
93052
93100
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-views-2d-layers-BaseLayerViewGL2D.html#tessellatePolygon Read more...}
93053
93101
  */
@@ -93055,7 +93103,7 @@ declare namespace __esri {
93055
93103
  /**
93056
93104
  * Tessellate a {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Polyline.html Polyline} into triangles.
93057
93105
  *
93058
- * @param polyline The input geometry. *The geometry must be simple*; if the input geometry is not simple, you must first create a simplified version of it using {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-geometryEngine.html#simplify geometryEngine.simplify}, and pass the simplified geometry to `tessellatePolyline`.
93106
+ * @param polyline The input geometry. *The geometry must be simple*; if the input geometry is not simple, you must first create a simplified version of it using {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-simplifyOperator.html simplifyOperator}, and pass the simplified geometry to `tessellatePolyline`.
93059
93107
  * @param width The width of the line; this will be used to scale xOffset and yOffset.
93060
93108
  *
93061
93109
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-views-2d-layers-BaseLayerViewGL2D.html#tessellatePolyline Read more...}
@@ -93319,7 +93367,7 @@ declare namespace __esri {
93319
93367
  visible: boolean;
93320
93368
  constructor(properties?: any);
93321
93369
  /**
93322
- * Starts the interactive placement of a direct line measurement.
93370
+ * Starts the interactive placement of an area measurement.
93323
93371
  *
93324
93372
  * @param options An object specifying additional options.
93325
93373
  *
@@ -108063,7 +108111,6 @@ declare namespace __esri {
108063
108111
  submit(): void;
108064
108112
  on(name: "value-change", eventHandler: BatchAttributeFormValueChangeEventHandler): IHandle;
108065
108113
  on(name: "submit", eventHandler: BatchAttributeFormSubmitEventHandler): IHandle;
108066
- on(name: "value-change", eventHandler: BatchAttributeFormValueChangeEvent1Handler): IHandle;
108067
108114
  }
108068
108115
 
108069
108116
  interface BatchAttributeFormProperties extends WidgetProperties {
@@ -108335,6 +108382,7 @@ declare namespace __esri {
108335
108382
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-BatchAttributeFormViewModel.html#submit Read more...}
108336
108383
  */
108337
108384
  submit(): void;
108385
+ on(name: "value-change", eventHandler: BatchAttributeFormViewModelValueChangeEventHandler): IHandle;
108338
108386
  on(name: "submit", eventHandler: BatchAttributeFormViewModelSubmitEventHandler): IHandle;
108339
108387
  }
108340
108388
 
@@ -108399,6 +108447,13 @@ declare namespace __esri {
108399
108447
  export interface BatchAttributeFormViewModelSubmitEvent {
108400
108448
  }
108401
108449
 
108450
+ export interface BatchAttributeFormViewModelValueChangeEvent {
108451
+ features: Graphic[];
108452
+ fieldName: string;
108453
+ name: "value-change";
108454
+ value: number | string | nullish;
108455
+ }
108456
+
108402
108457
  export class BatchFormInputs extends Accessor {
108403
108458
  /**
108404
108459
  * Returns an array of all the field inputs in the form, including those in groups.
@@ -108413,7 +108468,7 @@ declare namespace __esri {
108413
108468
  */
108414
108469
  readonly description: string | nullish;
108415
108470
  /**
108416
- * An array of field or group inputs that make up the module:esri/widgets/BatchAttributeForm/BatchAttributeForm.
108471
+ * An array of field or group inputs that make up the {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm.html BatchAttributeForm}.
108417
108472
  *
108418
108473
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-BatchFormInputs.html#inputs Read more...}
108419
108474
  */
@@ -108443,7 +108498,7 @@ declare namespace __esri {
108443
108498
  */
108444
108499
  readonly valid: boolean;
108445
108500
  /**
108446
- * The `BatchFormInputs` class is a read-only class that acts as a container for a set of inputs in a module:esri/widgets/BatchAttributeForm/BatchAttributeForm.
108501
+ * The `BatchFormInputs` class is a read-only class that acts as a container for a set of inputs in a {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-BatchAttributeFormViewModel.html BatchAttributeFormViewModel}.
108447
108502
  *
108448
108503
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-BatchFormInputs.html Read more...}
108449
108504
  */
@@ -108569,7 +108624,7 @@ declare namespace __esri {
108569
108624
  */
108570
108625
  declare readonly label: InputBase["label"];
108571
108626
  /**
108572
- * An array of layers included in the module:esri/widgets/BatchAttributeForm/BatchAttributeForm.
108627
+ * An array of layers included in the {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm.html BatchAttributeForm}.
108573
108628
  *
108574
108629
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-FieldInput.html#layers Read more...}
108575
108630
  */
@@ -108660,7 +108715,7 @@ declare namespace __esri {
108660
108715
  */
108661
108716
  declare existsInAllLayers: InputBase["existsInAllLayers"];
108662
108717
  /**
108663
- * An array of [@link module:esri/widgets/BatchAttributeForm/input/FieldInput field inputs} contained within the group.
108718
+ * An array of {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-FieldInput.html field inputs} contained within the group.
108664
108719
  *
108665
108720
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-GroupInput.html#inputs Read more...}
108666
108721
  */
@@ -108672,7 +108727,7 @@ declare namespace __esri {
108672
108727
  */
108673
108728
  declare readonly label: InputBase["label"];
108674
108729
  /**
108675
- * An array of layers included in the module:esri/widgets/BatchAttributeForm/BatchAttributeForm.
108730
+ * An array of layers included in the {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm.html BatchAttributeForm}.
108676
108731
  *
108677
108732
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-BatchAttributeForm-inputs-GroupInput.html#layers Read more...}
108678
108733
  */
@@ -108742,13 +108797,6 @@ declare namespace __esri {
108742
108797
  value: number | string | nullish;
108743
108798
  }
108744
108799
 
108745
- export interface BatchAttributeFormValueChangeEvent1 {
108746
- features: Graphic[];
108747
- fieldName: string;
108748
- name: "value-change";
108749
- value: number | string | nullish;
108750
- }
108751
-
108752
108800
  /**
108753
108801
  * An object containing properties that control the visibility of certain elements within the FeatureForm widget.
108754
108802
  *
@@ -110931,6 +110979,7 @@ declare namespace __esri {
110931
110979
  */
110932
110980
  get viewModel(): DaylightViewModel;
110933
110981
  set viewModel(value: DaylightViewModelProperties);
110982
+ on(name: "user-date-time-change", eventHandler: DaylightUserDateTimeChangeEventHandler): IHandle;
110934
110983
  }
110935
110984
 
110936
110985
  interface DaylightProperties extends WidgetProperties {
@@ -111157,6 +111206,9 @@ declare namespace __esri {
111157
111206
  export interface DaylightViewModelUserDateTimeChangeEvent {
111158
111207
  }
111159
111208
 
111209
+ export interface DaylightUserDateTimeChangeEvent {
111210
+ }
111211
+
111160
111212
  /**
111161
111213
  * The visible elements that are displayed within the widget.
111162
111214
  *
@@ -112716,6 +112768,12 @@ declare namespace __esri {
112716
112768
  * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Editor-EditorViewModel.html#featureFormViewModel Read more...}
112717
112769
  */
112718
112770
  readonly featureFormViewModel: FeatureFormViewModel | nullish;
112771
+ /**
112772
+ * The form's view model used to support the Editor widget.
112773
+ *
112774
+ * {@link https://developers.arcgis.com/javascript/latest/api-reference/esri-widgets-Editor-EditorViewModel.html#formViewModel Read more...}
112775
+ */
112776
+ readonly formViewModel: BatchAttributeFormViewModel | FeatureFormViewModel | nullish;
112719
112777
  /**
112720
112778
  * An array of editing configurations for individual layers.
112721
112779
  *
@@ -138187,8 +138245,8 @@ declare namespace __esri {
138187
138245
  export interface ResultAreaPropertiesExtend {
138188
138246
  type: "buffer" | "convexhull";
138189
138247
  distance: number;
138190
- unit: LinearUnits;
138191
- areaUnit: AreaUnits;
138248
+ unit: LengthUnit;
138249
+ areaUnit: AreaUnit;
138192
138250
  color: GraphicColor;
138193
138251
  show: boolean;
138194
138252
  }
package/kernel.js CHANGED
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import has from"./core/has.js";import{addQueryParameter as o}from"./core/urlUtils.js";export{buildDate,commitHash as revision}from"./support/revision.js";Symbol.dispose??=Symbol("Symbol.dispose"),Symbol.asyncDispose??=Symbol("Symbol.asyncDispose");const e="4.34";let s,r=e;function i(o){s=o}function t(e){const r=s?.findCredential(e);return r?.token?o(e,"token",r.token):e}r="4.34.0-next.22",has("host-webworker")||globalThis.$arcgis||Object.defineProperty(globalThis,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),has("host-webworker");export{t as addTokenParameter,r as fullVersion,s as id,i as setId,e as version};
5
+ import has from"./core/has.js";import{addQueryParameter as o}from"./core/urlUtils.js";export{buildDate,commitHash as revision}from"./support/revision.js";Symbol.dispose??=Symbol("Symbol.dispose"),Symbol.asyncDispose??=Symbol("Symbol.asyncDispose");const e="4.34";let s,r=e;function i(o){s=o}function t(e){const r=s?.findCredential(e);return r?.token?o(e,"token",r.token):e}r="4.34.0-next.23",has("host-webworker")||globalThis.$arcgis||Object.defineProperty(globalThis,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),has("host-webworker");export{t as addTokenParameter,r as fullVersion,s as id,i as setId,e as version};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{_ as e}from"../chunks/tslib.es6.js";import t from"../Color.js";import r from"../request.js";import{deprecatedProperty as o}from"../core/deprecate.js";import i from"../core/Error.js";import s from"../core/Logger.js";import{clamp as l}from"../core/mathUtils.js";import{MultiOriginJSONMixin as n}from"../core/MultiOriginJSONSupport.js";import{throwIfAbortError as a}from"../core/promiseUtils.js";import{watch as p,initial as y,whenOnce as m}from"../core/reactiveUtils.js";import{property as u}from"../core/accessorSupport/decorators/property.js";import{Integer as d}from"../core/accessorSupport/ensureType.js";import"../core/has.js";import"../core/RandomLCG.js";import{reader as c}from"../core/accessorSupport/decorators/reader.js";import{subclass as h}from"../core/accessorSupport/decorators/subclass.js";import{OriginId as f}from"../core/accessorSupport/PropertyOrigin.js";import v from"../geometry/Extent.js";import g from"../geometry/Polyline.js";import S from"../geometry/SpatialReference.js";import b from"./Layer.js";import{ArcGISService as j}from"./mixins/ArcGISService.js";import{BlendLayer as O,effectProperty as T}from"./mixins/BlendLayer.js";import{CustomParametersMixin as w}from"./mixins/CustomParametersMixin.js";import{OperationalLayer as I}from"./mixins/OperationalLayer.js";import{PortalLayer as L}from"./mixins/PortalLayer.js";import{ScaleRangeLayer as C}from"./mixins/ScaleRangeLayer.js";import{titleFromUrlAndName as x}from"./support/arcgisLayerUrl.js";import{opacity as U,id as P}from"./support/commonProperties.js";import{normalizeParsedUrlObject as E,urlProperty as N}from"./support/multiLayerServiceUtils.js";import M from"./support/PlaybackInfo.js";import{getVideoLayerCapabilities as k}from"./support/serviceCapabilitiesUtils.js";import V from"./support/TelemetryData.js";import F from"./support/TelemetryDisplay.js";import R from"./support/VideoFrame.js";import G from"./support/VideoTimeExtent.js";import J from"./video/VideoController.js";import{getFrameHorizonPoints as A,getGroundControlPoints as H,getTelemetryData as z,getServiceLayersInfo as q,getStyledTelemetrySymbol as D,getSensorTrailPoints as _,readVideoTimeExtent as B}from"./video/videoUtils.js";import W from"../symbols/CIMSymbol.js";import Q from"../symbols/PictureMarkerSymbol.js";import $ from"../symbols/SimpleFillSymbol.js";import Z from"../symbols/SimpleLineSymbol.js";import K from"../symbols/SimpleMarkerSymbol.js";import X from"../symbols/Symbol.js";import{write as Y}from"../symbols/support/jsonUtils.js";function ee(e,t){return{ignoreOrigin:this.originIdOf(t)<f.PORTAL_ITEM}}let te=[];const re=new t([255,127,0]),oe=new t([0,0,0,.05]),ie=new K({angle:0,color:re,size:10,style:"cross"}),se=new $({color:oe,outline:new Z({color:re,width:2})}),le=new Z({color:re,width:1}),ne=new K({angle:0,color:re,outline:{color:[255,255,255],width:1.33},size:10,style:"circle"}),ae=new Z({color:re,width:1}),pe={types:{base:X,key:"type",typeMap:{"simple-marker":K,"picture-marker":Q,cim:W}},json:{name:"drawingInfo.sensorSymbol",write:{writer:Y,overridePolicy:ee}}};function ye(e,t){return{type:t,json:{name:e,write:{overridePolicy:ee}}}}let me=class extends(O(C(j(I(L(n(w(b)))))))){constructor(e){super(e),this.capabilities=null,this.codecs=null,this.connectionInfo=null,this.controller=new J,this.copyright=null,this.created=null,this.customParameters=null,this.description=null,this.elevationSource=null,this.frame=null,this.frameCenterSymbol=ie.clone(),this.frameCount=null,this.frameEffect=null,this.frameOpacity=1,this.frameOutlineSymbol=se.clone(),this.fullExtent=null,this.initialExtent=null,this.layerId=null,this.operationalLayerType="ArcGISVideoLayer",this.playbackInfo=null,this.posterUrl=null,this.qualities=null,this.sensorSymbol=ne.clone(),this.sensorSightLineSymbol=le.clone(),this.sensorTrailSymbol=ae.clone(),this.serviceItemId=null,this.sourceJSON=null,this.sourceQuality=null,this.sourceType=null,this.spatialReference=S.WGS84,this.start=0,this.telemetryDisplay=new F,this.type="video",this.url=null,this.version=null,this.videoLayersInfo=null}initialize(){this.addHandles([p(()=>this.metadata,()=>{this.notifyChange("telemetry"),this.notifyChange("groundControlPoints"),this.notifyChange("frameHorizonPoints")}),p(()=>this.telemetry?.sensorLocation,e=>this._setSensorTrail(e),y)]),m(()=>this.loaded&&"can-play"===this.state&&this.duration>0).then(()=>{this.start>=0&&this.start<=this.duration&&this.setCurrentTime(this.start)})}destroy(){this.removeAllHandles(),this.controller&&this.controller.destroy()}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Video Service"],supportsData:!1},e).catch(a).then(()=>this._fetchService(t));return this.addResolvingPromise(r),Promise.resolve(this)}get autoplay(){return this.controller?.autoplay??!1}set autoplay(e){this.controller.autoplay=e}get buffered(){return this.controller.buffered}readCapabilitiesFromService(e,t){return k(t)}readConnectionInfo(e,t){const r=Object.values(t.connectionUrl);return r?.length&&(this.controller.playerUrl=r[0]),t.connectionUrl}get currentTime(){return this.controller.currentTime}get duration(){return this.controller.duration}get ended(){return this.controller.ended}get frameHorizonPoints(){return A(this.metadata)}get groundControlPoints(){return H(this.metadata)}get isLive(){return this.controller?.isLive??!1}get livestreamStatus(){return this.controller?.livestreamStatus}get loop(){return this.controller.loop}set loop(e){this.controller.loop=e}get metadata(){return this.controller?.currentMetadata}get mimeType(){return this.controller?.mimeType}get muted(){return this.controller.muted}set muted(e){this.controller.muted=e}get parsedUrl(){return E(this)}get playbackRate(){return this.controller.rate}set playbackRate(e){this.controller.rate=e}get playerUrl(){return this.controller.playerUrl}get playing(){return this.controller.playing}get started(){return this.controller?.started??!1}get state(){return this.controller.state}get telemetry(){return z(this.metadata)}readTitleFromService(e,{name:t}){return this.url?x(this.url,t):t}get videoElement(){return this.controller?.element}get videoHeight(){return this.controller?.videoHeight}readLayerInfosFromService(e,t){return q(t)}get videoTimeExtent(){return o(s.getLogger(this),"videoTimeExtent",{replacement:"fullTimeExtent",version:"4.33",warnOnce:!0}),this.fullTimeExtent}get videoWidth(){return this.controller?.videoWidth}get volume(){return this.controller?.volume??0}set volume(e){this.controller.volume=e}get waiting(){return this.controller.waiting}play(){this.controller.play()}pause(){this.controller.pause()}reset(){te=[],this.controller.reset()}setCurrentTime(e){if(this.duration<0)return;const t=l(e,0,this.duration);this.controller.setCurrentTime(t)}toGround(e,t){return this.controller?.sensorModel?.metadataSupportsTransforms?this.controller.sensorModel.transformImageToGeo(e,t):null}toVideo(e){if(!this.controller?.sensorModel?.metadataSupportsTransforms)return null;const t=this.controller.sensorModel.transformGeoToImage(e.x,e.y,e.z);return{x:t[0],y:t[1]}}updateTelemetryColor(e){this.frameCenterSymbol=D(this.frameCenterSymbol,e)??ie,this.frameOutlineSymbol=D(this.frameOutlineSymbol,e,oe)??se,this.sensorSightLineSymbol=D(this.sensorSightLineSymbol,e)??le,this.sensorTrailSymbol=D(this.sensorTrailSymbol,e)??ae,this.sensorSymbol=D(this.sensorSymbol,e)??ne}write(e,t){return null==this.layerId?(t?.messages?.push(new i("layer:unsupported",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' cannot be saved to a web map, web scene, or portal item. The ArcGIS server version must be greater than 11.2.`)),null):super.write(e,t)}async _fetchService(e){if(this.sourceJSON)return void this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl});const{data:t,ssl:o}=await r(this.url,{query:{f:"json",...this.parsedUrl.query,...this.customParameters},signal:e});if(o&&(this.url=this.url.replace(/^http:/i,"https:")),!t?.currentVersion)return t.currentVersion="11.2",this.sourceJSON=t,void this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl});if(this.layerId??=t.layers?.[0]?.id??null,null==this.layerId)throw new i("arcgis-layers:url-mismatch","The url is not a valid arcgis resource");const{data:s}=await r(this.parsedUrl.path,{query:{f:"json",...this.customParameters},signal:e});this.sourceJSON={...t,...s},this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl})}_setSensorTrail(e){if(!e)return;const t=_(e,te);te=[...t];const r=te.map(e=>e.toArray()),o=new g({hasZ:e.hasZ,paths:[r]});this.telemetry.sensorTrail=o.clone()}};e([u({type:Boolean,json:{write:{ignoreOrigin:!0}}})],me.prototype,"autoplay",null),e([u({readOnly:!0})],me.prototype,"buffered",null),e([u({readOnly:!0})],me.prototype,"cameraInfo",void 0),e([u({readOnly:!0,json:{read:!1}})],me.prototype,"capabilities",void 0),e([c("service","capabilities",["supportsAppend","supportsCoverageQuery","supportsExportClip","supportsExportFrameset","supportsMensuration","supportsPreviews","supportsUpdate"])],me.prototype,"readCapabilitiesFromService",null),e([u({readOnly:!0})],me.prototype,"codecs",void 0),e([u({readOnly:!0})],me.prototype,"connectionInfo",void 0),e([c("connectionInfo",["connectionUrl"])],me.prototype,"readConnectionInfo",null),e([u()],me.prototype,"controller",void 0),e([u({type:String})],me.prototype,"copyright",void 0),e([u({readOnly:!0,type:Date})],me.prototype,"created",void 0),e([u({type:Number})],me.prototype,"currentTime",null),e([u({json:{write:!1}})],me.prototype,"customParameters",void 0),e([u({type:String})],me.prototype,"description",void 0),e([u({type:Number})],me.prototype,"duration",null),e([u({readOnly:!0})],me.prototype,"elevationSource",void 0),e([u({type:Boolean})],me.prototype,"ended",null),e([u({type:R})],me.prototype,"frame",void 0),e([u(ye("drawingInfo.frameCenterSymbol",K))],me.prototype,"frameCenterSymbol",void 0),e([u({readOnly:!0,type:d})],me.prototype,"frameCount",void 0),e([u(T)],me.prototype,"frameEffect",void 0),e([u(U)],me.prototype,"frameOpacity",void 0),e([u(ye("drawingInfo.frameOutlineSymbol",$))],me.prototype,"frameOutlineSymbol",void 0),e([u({type:v})],me.prototype,"fullExtent",void 0),e([u({readOnly:!0})],me.prototype,"frameHorizonPoints",null),e([u({readOnly:!0,json:{read:{reader:B,source:"time"}},type:G})],me.prototype,"fullTimeExtent",void 0),e([u({readOnly:!0})],me.prototype,"groundControlPoints",null),e([u(P)],me.prototype,"id",void 0),e([u({type:v})],me.prototype,"initialExtent",void 0),e([u({readOnly:!0})],me.prototype,"isLive",null),e([u({type:d,json:{read:!1,origins:{service:{read:{source:"id"}}}}})],me.prototype,"layerId",void 0),e([u({readOnly:!0})],me.prototype,"livestreamStatus",null),e([u({type:Boolean})],me.prototype,"loop",null),e([u({readOnly:!0})],me.prototype,"metadata",null),e([u({readOnly:!0})],me.prototype,"mimeType",null),e([u({type:Boolean,json:{write:{ignoreOrigin:!0}}})],me.prototype,"muted",null),e([u({type:["ArcGISVideoLayer"]})],me.prototype,"operationalLayerType",void 0),e([u({readOnly:!0})],me.prototype,"parsedUrl",null),e([u({type:M})],me.prototype,"playbackInfo",void 0),e([u({type:Number})],me.prototype,"playbackRate",null),e([u({readOnly:!0,type:String})],me.prototype,"playerUrl",null),e([u({readOnly:!0})],me.prototype,"playing",null),e([u({readOnly:!0,json:{read:{source:"poster"}}})],me.prototype,"posterUrl",void 0),e([u({readOnly:!0})],me.prototype,"qualities",void 0),e([u(pe)],me.prototype,"sensorSymbol",void 0),e([u(ye("drawingInfo.sensorSightLineSymbol",Z))],me.prototype,"sensorSightLineSymbol",void 0),e([u(ye("drawingInfo.sensorTrailSymbol",Z))],me.prototype,"sensorTrailSymbol",void 0),e([u({readOnly:!0})],me.prototype,"serviceItemId",void 0),e([u()],me.prototype,"sourceJSON",void 0),e([u({readOnly:!0})],me.prototype,"sourceQuality",void 0),e([u({readOnly:!0,json:{name:"serviceType"}})],me.prototype,"sourceType",void 0),e([u()],me.prototype,"spatialReference",void 0),e([u({json:{write:!0}})],me.prototype,"start",void 0),e([u({readOnly:!0})],me.prototype,"started",null),e([u({readOnly:!0,type:String})],me.prototype,"state",null),e([u({readOnly:!0,type:V})],me.prototype,"telemetry",null),e([u({type:F,nonNullable:!0,json:{write:{ignoreOrigin:!0}}})],me.prototype,"telemetryDisplay",void 0),e([c("service","title",["name"])],me.prototype,"readTitleFromService",null),e([u({readOnly:!0})],me.prototype,"type",void 0),e([u(N())],me.prototype,"url",void 0),e([u({readOnly:!0,type:Number,json:{read:{source:"currentVersion"}}})],me.prototype,"version",void 0),e([u({readOnly:!0})],me.prototype,"videoElement",null),e([u({readOnly:!0})],me.prototype,"videoHeight",null),e([u({readOnly:!0,json:{read:!1}})],me.prototype,"videoLayersInfo",void 0),e([c("service","videoLayersInfo",["id","name","poster","serviceType","type"])],me.prototype,"readLayerInfosFromService",null),e([u({type:G,readOnly:!0})],me.prototype,"videoTimeExtent",null),e([u({readOnly:!0})],me.prototype,"videoWidth",null),e([u()],me.prototype,"volume",null),e([u({readOnly:!0})],me.prototype,"waiting",null),me=e([h("esri.layers.VideoLayer")],me);const ue=me;export{ue as default};
5
+ import{_ as e}from"../chunks/tslib.es6.js";import t from"../Color.js";import r from"../request.js";import{deprecatedProperty as o}from"../core/deprecate.js";import i from"../core/Error.js";import s from"../core/Logger.js";import{clamp as l}from"../core/mathUtils.js";import{MultiOriginJSONMixin as n}from"../core/MultiOriginJSONSupport.js";import{throwIfAbortError as a}from"../core/promiseUtils.js";import{watch as p,initial as y,whenOnce as m}from"../core/reactiveUtils.js";import{property as u}from"../core/accessorSupport/decorators/property.js";import{Integer as d}from"../core/accessorSupport/ensureType.js";import"../core/has.js";import"../core/RandomLCG.js";import{reader as c}from"../core/accessorSupport/decorators/reader.js";import{subclass as h}from"../core/accessorSupport/decorators/subclass.js";import{OriginId as f}from"../core/accessorSupport/PropertyOrigin.js";import v from"../geometry/Extent.js";import g from"../geometry/Polyline.js";import S from"../geometry/SpatialReference.js";import b from"./Layer.js";import{ArcGISService as O}from"./mixins/ArcGISService.js";import{BlendLayer as j,effectProperty as T}from"./mixins/BlendLayer.js";import{CustomParametersMixin as w}from"./mixins/CustomParametersMixin.js";import{OperationalLayer as I}from"./mixins/OperationalLayer.js";import{PortalLayer as L}from"./mixins/PortalLayer.js";import{ScaleRangeLayer as C}from"./mixins/ScaleRangeLayer.js";import{titleFromUrlAndName as x}from"./support/arcgisLayerUrl.js";import{opacity as U,id as P}from"./support/commonProperties.js";import{normalizeParsedUrlObject as E,urlProperty as N}from"./support/multiLayerServiceUtils.js";import M from"./support/PlaybackInfo.js";import{getVideoLayerCapabilities as k}from"./support/serviceCapabilitiesUtils.js";import V from"./support/TelemetryData.js";import F from"./support/TelemetryDisplay.js";import R from"./support/VideoFrame.js";import G from"./support/VideoTimeExtent.js";import H from"./video/VideoController.js";import{getFrameHorizonPoints as J,getGroundControlPoints as A,getTelemetryData as z,getServiceLayersInfo as q,getStyledTelemetrySymbol as D,getSensorTrailPoints as _,readVideoTimeExtent as B}from"./video/videoUtils.js";import W from"../symbols/CIMSymbol.js";import Q from"../symbols/PictureMarkerSymbol.js";import $ from"../symbols/SimpleFillSymbol.js";import Z from"../symbols/SimpleLineSymbol.js";import K from"../symbols/SimpleMarkerSymbol.js";import X from"../symbols/Symbol.js";import{write as Y}from"../symbols/support/jsonUtils.js";function ee(e,t){return{ignoreOrigin:this.originIdOf(t)<f.PORTAL_ITEM}}let te=[];const re=new t([255,127,0]),oe=new t([0,0,0,.05]),ie=new K({angle:0,color:re,size:10,style:"cross"}),se=new $({color:oe,outline:new Z({color:re,width:2})}),le=new Z({color:re,width:1}),ne=new K({angle:0,color:re,outline:{color:[255,255,255],width:1.33},size:10,style:"circle"}),ae=new Z({color:re,width:1}),pe={types:{base:X,key:"type",typeMap:{"simple-marker":K,"picture-marker":Q,cim:W}},json:{name:"drawingInfo.sensorSymbol",write:{writer:Y,overridePolicy:ee}}};function ye(e,t){return{type:t,json:{name:e,write:{overridePolicy:ee}}}}let me=class extends(j(C(O(I(L(n(w(b)))))))){constructor(e){super(e),this.capabilities=null,this.codecs=null,this.connectionInfo=null,this.controller=new H,this.copyright=null,this.created=null,this.customParameters=null,this.description=null,this.elevationSource=null,this.frame=null,this.frameCenterSymbol=ie.clone(),this.frameCount=null,this.frameEffect=null,this.frameOpacity=1,this.frameOutlineSymbol=se.clone(),this.fullExtent=null,this.initialExtent=null,this.layerId=null,this.operationalLayerType="ArcGISVideoLayer",this.playbackInfo=null,this.posterUrl=null,this.qualities=null,this.sensorSymbolOrientation={source:"platformHeading",symbolOffset:0},this.sensorSymbol=ne.clone(),this.sensorSightLineSymbol=le.clone(),this.sensorTrailSymbol=ae.clone(),this.serviceItemId=null,this.sourceJSON=null,this.sourceQuality=null,this.sourceType=null,this.spatialReference=S.WGS84,this.start=0,this.telemetryDisplay=new F,this.type="video",this.url=null,this.version=null,this.videoLayersInfo=null}initialize(){this.addHandles([p(()=>this.metadata,()=>{this.notifyChange("telemetry"),this.notifyChange("groundControlPoints"),this.notifyChange("frameHorizonPoints")}),p(()=>this.telemetry?.sensorLocation,e=>this._setSensorTrail(e),y)]),m(()=>this.loaded&&"can-play"===this.state&&this.duration>0).then(()=>{this.start>=0&&this.start<=this.duration&&this.setCurrentTime(this.start)})}destroy(){this.removeAllHandles(),this.controller&&this.controller.destroy()}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Video Service"],supportsData:!1},e).catch(a).then(()=>this._fetchService(t));return this.addResolvingPromise(r),Promise.resolve(this)}get autoplay(){return this.controller?.autoplay??!1}set autoplay(e){this.controller.autoplay=e}get buffered(){return this.controller.buffered}readCapabilitiesFromService(e,t){return k(t)}readConnectionInfo(e,t){const r=Object.values(t.connectionUrl);return r?.length&&(this.controller.playerUrl=r[0]),t.connectionUrl}get currentTime(){return this.controller.currentTime}get duration(){return this.controller.duration}get ended(){return this.controller.ended}get frameHorizonPoints(){return J(this.metadata)}get groundControlPoints(){return A(this.metadata)}get isLive(){return this.controller?.isLive??!1}get livestreamStatus(){return this.controller?.livestreamStatus}get loop(){return this.controller.loop}set loop(e){this.controller.loop=e}get metadata(){return this.controller?.currentMetadata}get mimeType(){return this.controller?.mimeType}get muted(){return this.controller.muted}set muted(e){this.controller.muted=e}get parsedUrl(){return E(this)}get playbackRate(){return this.controller.rate}set playbackRate(e){this.controller.rate=e}get playerUrl(){return this.controller.playerUrl}get playing(){return this.controller.playing}get started(){return this.controller?.started??!1}get state(){return this.controller.state}get telemetry(){return z(this.metadata)}readTitleFromService(e,{name:t}){return this.url?x(this.url,t):t}get videoElement(){return this.controller?.element}get videoHeight(){return this.controller?.videoHeight}readLayerInfosFromService(e,t){return q(t)}get videoTimeExtent(){return o(s.getLogger(this),"videoTimeExtent",{replacement:"fullTimeExtent",version:"4.33",warnOnce:!0}),this.fullTimeExtent}get videoWidth(){return this.controller?.videoWidth}get volume(){return this.controller?.volume??0}set volume(e){this.controller.volume=e}get waiting(){return this.controller.waiting}play(){this.controller.play()}pause(){this.controller.pause()}reset(){te=[],this.controller.reset()}setCurrentTime(e){if(this.duration<0)return;const t=l(e,0,this.duration);this.controller.setCurrentTime(t)}toGround(e,t){return this.controller?.sensorModel?.metadataSupportsTransforms?this.controller.sensorModel.transformImageToGeo(e,t):null}toVideo(e){if(!this.controller?.sensorModel?.metadataSupportsTransforms)return null;const t=this.controller.sensorModel.transformGeoToImage(e.x,e.y,e.z);return{x:t[0],y:t[1]}}updateTelemetryColor(e){this.frameCenterSymbol=D(this.frameCenterSymbol,e)??ie,this.frameOutlineSymbol=D(this.frameOutlineSymbol,e,oe)??se,this.sensorSightLineSymbol=D(this.sensorSightLineSymbol,e)??le,this.sensorTrailSymbol=D(this.sensorTrailSymbol,e)??ae,this.sensorSymbol=D(this.sensorSymbol,e)??ne}write(e,t){return null==this.layerId?(t?.messages?.push(new i("layer:unsupported",`Layer (${this.title}, ${this.id}) of type '${this.declaredClass}' cannot be saved to a web map, web scene, or portal item. The ArcGIS server version must be greater than 11.2.`)),null):super.write(e,t)}async _fetchService(e){if(this.sourceJSON)return void this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl});const{data:t,ssl:o}=await r(this.url,{query:{f:"json",...this.parsedUrl.query,...this.customParameters},signal:e});if(o&&(this.url=this.url.replace(/^http:/i,"https:")),!t?.currentVersion)return t.currentVersion="11.2",this.sourceJSON=t,void this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl});if(this.layerId??=t.layers?.[0]?.id??null,null==this.layerId)throw new i("arcgis-layers:url-mismatch","The url is not a valid arcgis resource");const{data:s}=await r(this.parsedUrl.path,{query:{f:"json",...this.customParameters},signal:e});this.sourceJSON={...t,...s},this.read(this.sourceJSON,{origin:"service",url:this.parsedUrl})}_setSensorTrail(e){if(!e)return;const t=_(e,te);te=[...t];const r=te.map(e=>e.toArray()),o=new g({hasZ:e.hasZ,paths:[r]});this.telemetry.sensorTrail=o.clone()}};e([u({type:Boolean,json:{write:{ignoreOrigin:!0}}})],me.prototype,"autoplay",null),e([u({readOnly:!0})],me.prototype,"buffered",null),e([u({readOnly:!0})],me.prototype,"cameraInfo",void 0),e([u({readOnly:!0,json:{read:!1}})],me.prototype,"capabilities",void 0),e([c("service","capabilities",["supportsAppend","supportsCoverageQuery","supportsExportClip","supportsExportFrameset","supportsMensuration","supportsPreviews","supportsUpdate"])],me.prototype,"readCapabilitiesFromService",null),e([u({readOnly:!0})],me.prototype,"codecs",void 0),e([u({readOnly:!0})],me.prototype,"connectionInfo",void 0),e([c("connectionInfo",["connectionUrl"])],me.prototype,"readConnectionInfo",null),e([u()],me.prototype,"controller",void 0),e([u({type:String})],me.prototype,"copyright",void 0),e([u({readOnly:!0,type:Date})],me.prototype,"created",void 0),e([u({type:Number})],me.prototype,"currentTime",null),e([u({json:{write:!1}})],me.prototype,"customParameters",void 0),e([u({type:String})],me.prototype,"description",void 0),e([u({type:Number})],me.prototype,"duration",null),e([u({readOnly:!0})],me.prototype,"elevationSource",void 0),e([u({type:Boolean})],me.prototype,"ended",null),e([u({type:R})],me.prototype,"frame",void 0),e([u(ye("drawingInfo.frameCenterSymbol",K))],me.prototype,"frameCenterSymbol",void 0),e([u({readOnly:!0,type:d})],me.prototype,"frameCount",void 0),e([u(T)],me.prototype,"frameEffect",void 0),e([u(U)],me.prototype,"frameOpacity",void 0),e([u(ye("drawingInfo.frameOutlineSymbol",$))],me.prototype,"frameOutlineSymbol",void 0),e([u({type:v})],me.prototype,"fullExtent",void 0),e([u({readOnly:!0})],me.prototype,"frameHorizonPoints",null),e([u({readOnly:!0,json:{read:{reader:B,source:"time"}},type:G})],me.prototype,"fullTimeExtent",void 0),e([u({readOnly:!0})],me.prototype,"groundControlPoints",null),e([u(P)],me.prototype,"id",void 0),e([u({type:v})],me.prototype,"initialExtent",void 0),e([u({readOnly:!0})],me.prototype,"isLive",null),e([u({type:d,json:{read:!1,origins:{service:{read:{source:"id"}}}}})],me.prototype,"layerId",void 0),e([u({readOnly:!0})],me.prototype,"livestreamStatus",null),e([u({type:Boolean})],me.prototype,"loop",null),e([u({readOnly:!0})],me.prototype,"metadata",null),e([u({readOnly:!0})],me.prototype,"mimeType",null),e([u({type:Boolean,json:{write:{ignoreOrigin:!0}}})],me.prototype,"muted",null),e([u({type:["ArcGISVideoLayer"]})],me.prototype,"operationalLayerType",void 0),e([u({readOnly:!0})],me.prototype,"parsedUrl",null),e([u({type:M})],me.prototype,"playbackInfo",void 0),e([u({type:Number})],me.prototype,"playbackRate",null),e([u({readOnly:!0,type:String})],me.prototype,"playerUrl",null),e([u({readOnly:!0})],me.prototype,"playing",null),e([u({readOnly:!0,json:{read:{source:"poster"}}})],me.prototype,"posterUrl",void 0),e([u({readOnly:!0})],me.prototype,"qualities",void 0),e([u()],me.prototype,"sensorSymbolOrientation",void 0),e([u(pe)],me.prototype,"sensorSymbol",void 0),e([u(ye("drawingInfo.sensorSightLineSymbol",Z))],me.prototype,"sensorSightLineSymbol",void 0),e([u(ye("drawingInfo.sensorTrailSymbol",Z))],me.prototype,"sensorTrailSymbol",void 0),e([u({readOnly:!0})],me.prototype,"serviceItemId",void 0),e([u()],me.prototype,"sourceJSON",void 0),e([u({readOnly:!0})],me.prototype,"sourceQuality",void 0),e([u({readOnly:!0,json:{name:"serviceType"}})],me.prototype,"sourceType",void 0),e([u()],me.prototype,"spatialReference",void 0),e([u({json:{write:!0}})],me.prototype,"start",void 0),e([u({readOnly:!0})],me.prototype,"started",null),e([u({readOnly:!0,type:String})],me.prototype,"state",null),e([u({readOnly:!0,type:V})],me.prototype,"telemetry",null),e([u({type:F,nonNullable:!0,json:{write:{ignoreOrigin:!0}}})],me.prototype,"telemetryDisplay",void 0),e([c("service","title",["name"])],me.prototype,"readTitleFromService",null),e([u({readOnly:!0})],me.prototype,"type",void 0),e([u(N())],me.prototype,"url",void 0),e([u({readOnly:!0,type:Number,json:{read:{source:"currentVersion"}}})],me.prototype,"version",void 0),e([u({readOnly:!0})],me.prototype,"videoElement",null),e([u({readOnly:!0})],me.prototype,"videoHeight",null),e([u({readOnly:!0,json:{read:!1}})],me.prototype,"videoLayersInfo",void 0),e([c("service","videoLayersInfo",["id","name","poster","serviceType","type"])],me.prototype,"readLayerInfosFromService",null),e([u({type:G,readOnly:!0})],me.prototype,"videoTimeExtent",null),e([u({readOnly:!0})],me.prototype,"videoWidth",null),e([u()],me.prototype,"volume",null),e([u({readOnly:!0})],me.prototype,"waiting",null),me=e([h("esri.layers.VideoLayer")],me);const ue=me;export{ue as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{_ as e}from"../../chunks/tslib.es6.js";import r from"../../core/JSONSupport.js";import{clone as o}from"../../core/lang.js";import t from"../../core/Warning.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as p}from"../../core/accessorSupport/decorators/subclass.js";import{writer as i}from"../../core/accessorSupport/decorators/writer.js";import{persistable as a}from"../../core/accessorSupport/decorators/persistable.js";import c from"../../geometry/Polygon.js";import{canProjectWithoutEngine as l,projectPolygon as n}from"../../geometry/projectionUtils.js";var m;let f=m=class extends r{constructor(e){super(e),this.geometry=null,this.type="clip"}writeGeometry(e,r,o,s){if(s.layer?.spatialReference&&!s.layer.spatialReference.equals(this.geometry.spatialReference)){if(!l(e.spatialReference,s.layer.spatialReference))return void(s?.messages&&s.messages.push(new t("scenemodification:unsupported","Scene modifications with incompatible spatial references are not supported",{modification:this,spatialReference:s.layer.spatialReference,context:s})));const p=new c;n(e,p,s.layer.spatialReference),r[o]=p.toJSON(s)}else r[o]=e.toJSON(s);delete r[o].spatialReference}clone(){return new m({geometry:o(this.geometry),type:this.type})}};e([s({type:c}),a()],f.prototype,"geometry",void 0),e([i(["web-scene","portal-item"],"geometry")],f.prototype,"writeGeometry",null),e([s({type:["clip","mask","replace"],nonNullable:!0}),a()],f.prototype,"type",void 0),f=m=e([p("esri.layers.support.SceneModification")],f);export{f as default};
5
+ import{_ as e}from"../../chunks/tslib.es6.js";import r from"../../core/JSONSupport.js";import{clone as o}from"../../core/lang.js";import t from"../../core/Warning.js";import{property as s}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import{subclass as p}from"../../core/accessorSupport/decorators/subclass.js";import{writer as i}from"../../core/accessorSupport/decorators/writer.js";import{persistable as a}from"../../core/accessorSupport/decorators/persistable.js";import c from"../../geometry/Polygon.js";import{canProjectWithoutEngine as m,projectPolygon as n}from"../../geometry/projectionUtils.js";var l;let y=l=class extends r{constructor(e){super(e),this.geometry=null,this.type="clip"}writeGeometry(e,r,o,s){if(s.layer?.spatialReference&&!s.layer.spatialReference.equals(this.geometry.spatialReference)){if(!m(e.spatialReference,s.layer.spatialReference))return void(s?.messages&&s.messages.push(new t("scenemodification:unsupported","Scene modifications with incompatible spatial references are not supported",{modification:this,spatialReference:s.layer.spatialReference,context:s})));const p=new c;n(e,p,s.layer.spatialReference),r[o]=p.toJSON(s)}else r[o]=e.toJSON(s)}clone(){return new l({geometry:o(this.geometry),type:this.type})}};e([s({type:c}),a()],y.prototype,"geometry",void 0),e([i(["web-scene","portal-item"],"geometry")],y.prototype,"writeGeometry",null),e([s({type:["clip","mask","replace"],nonNullable:!0}),a()],y.prototype,"type",void 0),y=l=e([p("esri.layers.support.SceneModification")],y);export{y as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{_ as r}from"../../chunks/tslib.es6.js";import o from"../../request.js";import t from"../../core/Collection.js";import e from"../../core/JSONSupport.js";import{urlToObject as s}from"../../core/urlUtils.js";import{property as i}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as c}from"../../core/accessorSupport/decorators/subclass.js";import p from"./SceneModification.js";var m;let n=m=class extends(e.JSONSupportMixin(t.ofType(p))){constructor(r){super(r),this.url=null}clone(){return new m({url:this.url,items:this.items.map(r=>r.clone())})}toJSON(r){return this.toArray().map(o=>o.toJSON(r)).filter(r=>!!r.geometry)}static fromJSON(r,o){const t=new m;for(const e of r)t.add(p.fromJSON(e,o));return t}static async fromUrl(r,t,e){const i={url:s(r),origin:"service"},c=await o(r,{responseType:"json",signal:e?.signal}),n=t.toJSON(),a=[];for(const o of c.data)a.push(p.fromJSON({...o,geometry:{...o.geometry,spatialReference:n}},i));return new m({url:r,items:a})}};r([i({type:String})],n.prototype,"url",void 0),n=m=r([c("esri.layers.support.SceneModifications")],n);export{n as default};
5
+ import{_ as r}from"../../chunks/tslib.es6.js";import o from"../../request.js";import t from"../../core/Collection.js";import e from"../../core/JSONSupport.js";import{urlToObject as s}from"../../core/urlUtils.js";import{property as i}from"../../core/accessorSupport/decorators/property.js";import"../../core/has.js";import"../../core/Logger.js";import"../../core/RandomLCG.js";import{subclass as c}from"../../core/accessorSupport/decorators/subclass.js";import p from"./SceneModification.js";var m;let n=m=class extends(e.JSONSupportMixin(t.ofType(p))){constructor(r){super(r),this.url=null}clone(){return new m({url:this.url,items:this.items.map(r=>r.clone())})}toJSON(r){return this.toArray().map(o=>o.toJSON(r)).filter(r=>!!r.geometry)}static fromJSON(r,o){const t=new m;for(const e of r)t.add(p.fromJSON(e,o));return t}static async fromUrl(r,t,e){const i={url:s(r),origin:"service"},c=await o(r,{responseType:"json",signal:e?.signal}),n=t.toJSON(),a=[];for(const o of c.data)a.push(p.fromJSON({...o,geometry:{spatialReference:n,...o.geometry}},i));return new m({url:r,items:a})}};r([i({type:String})],n.prototype,"url",void 0),n=m=r([c("esri.layers.support.SceneModifications")],n);export{n as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.34/esri/copyright.txt for details.
4
4
  */
5
- import{_ as t}from"../../../chunks/tslib.es6.js";import e from"../../../core/Error.js";import{property as r}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as s}from"../../../core/accessorSupport/decorators/subclass.js";import o from"../../../geometry/Extent.js";import a from"../../../geometry/Point.js";import i from"../../../geometry/SpatialReference.js";import n from"../PixelBlock.js";import l from"../RasterInfo.js";import f from"../RasterStorageInfo.js";import c from"./BaseRaster.js";import{parseSpatialReference as p,parsePAMInfo as m}from"./pamParser.js";import{getElement as h,getElementValue as u}from"./xmlUtilities.js";import{isPlatformLittleEndian as g}from"../rasterFormats/utils.js";import{estimateStatisticsFromHistograms as d}from"../rasterFunctions/stretchUtils.js";const y=new Map;y.set("Int8","s8"),y.set("UInt8","u8"),y.set("Int16","s16"),y.set("UInt16","u16"),y.set("Int32","s32"),y.set("UInt32","u32"),y.set("Float32","f32"),y.set("Float64","f32"),y.set("Double64","f32");const x=new Map;x.set("none",{blobExtension:".til",isOneSegment:!0,decoderFormat:"bip"}),x.set("lerc",{blobExtension:".lrc",isOneSegment:!1,decoderFormat:"lerc"}),x.set("deflate",{blobExtension:".pzp",isOneSegment:!0,decoderFormat:"deflate"}),x.set("jpeg",{blobExtension:".pjg",isOneSegment:!0,decoderFormat:"jpg"});let w=class extends c{constructor(){super(...arguments),this._files=null,this._storageIndex=null,this.datasetFormat="MRF"}async fetchRawTile(t,e,r,s={}){const{blockWidth:o,blockHeight:a,blockBoundary:i}=this.rasterInfo.storageInfo,l=i[t];if(!l||l.maxRow<e||l.maxCol<r||l.minRow>e||l.minCol>r)return null;const{bandCount:f,pixelType:c}=this.rasterInfo,{ranges:p,actualTileWidth:m,actualTileHeight:h}=this._getTileLocation(t,e,r);if(!p||0===p.length)return null;if(0===p[0].from&&0===p[0].to){const t=new Uint8Array(o*a);return new n({width:o,height:a,pixels:void 0,mask:t,validPixelCount:0})}const{bandIds:u}=this.ioConfig,g=this._getBandSegmentCount(),d=[];let y=0;for(y=0;y<g;y++)u&&!u.includes(y)||d.push(this.request(this._files.data,{range:{from:p[y].from,to:p[y].to},responseType:"array-buffer",signal:s.signal}));const w=await Promise.all(d),I=w.map(t=>t.data.byteLength).reduce((t,e)=>t+e),b=new Uint8Array(I),R=[];let A=0;for(y=0;y<g;y++)R.push(A),b.set(new Uint8Array(w[y].data),A),A+=w[y].data.byteLength;const F=x.get(this.rasterInfo.storageInfo.compression).decoderFormat,_=await this.decodePixelBlock(b.buffer,{width:o,height:a,format:F,planes:u?.length||f,offsets:R,pixelType:c});if(null==_)return null;let{noDataValue:S}=this.rasterInfo;if(null!=S&&"lerc"!==F&&!_.mask&&(S=S[0],null!=S)){const t=_.width*_.height,e=new Uint8Array(t);if(Math.abs(S)>1e24)for(y=0;y<t;y++)Math.abs((_.pixels[0][y]-S)/S)>1e-6&&(e[y]=1);else for(y=0;y<t;y++)_.pixels[0][y]!==S&&(e[y]=1);_.mask=e}let k=0,M=0;if(m!==o||h!==a){let t=_.mask;if(t)for(y=0;y<a;y++)if(M=y*o,y<h)for(k=m;k<o;k++)t[M+k]=0;else for(k=0;k<o;k++)t[M+k]=0;else for(t=new Uint8Array(o*a),_.mask=t,y=0;y<h;y++)for(M=y*o,k=0;k<m;k++)t[M+k]=1}return _}async _open(t){this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const e=t?t.signal:null,r=await this.request(this.url,{responseType:"xml",signal:e}),{rasterInfo:s,files:o}=this._parseHeader(r.data),{skipMapInfo:a,skipExtensions:i=[]}=this.ioConfig;if(!i.includes("aux.xml")&&!a){const e=await this._fetchAuxiliaryData(t);null!=e&&(s.statistics=e.statistics??s.statistics,s.histograms=e.histograms,e.histograms&&null==s.statistics&&(s.statistics=d(e.histograms)))}a&&this.updateImageSpaceRasterInfo(s),this._set("rasterInfo",s),this._files=o;const n=await this.request(o.index,{responseType:"array-buffer",signal:e});this._storageIndex=I(n.data);const{blockWidth:l,blockHeight:f}=this.rasterInfo.storageInfo,c=this.rasterInfo.storageInfo.pyramidScalingFactor,{width:p,height:m}=this.rasterInfo,h=[],u=this._getBandSegmentCount();let g=0,y=-1;for(;g<this._storageIndex.length;){y++;const t=Math.ceil(p/l/c**y)-1,e=Math.ceil(m/f/c**y)-1;g+=(t+1)*(e+1)*u*4,h.push({maxRow:e,maxCol:t,minCol:0,minRow:0})}this.rasterInfo.storageInfo.blockBoundary=h,y>0&&(this.rasterInfo.storageInfo.firstPyramidLevel=1,this.rasterInfo.storageInfo.maximumPyramidLevel=y),this.updateTileInfo()}_getBandSegmentCount(){return x.get(this.rasterInfo.storageInfo.compression).isOneSegment?1:this.rasterInfo.bandCount}_getTileLocation(t,e,r){const{blockWidth:s,blockHeight:o,pyramidScalingFactor:a}=this.rasterInfo.storageInfo,{width:i,height:n}=this.rasterInfo,l=this._getBandSegmentCount();let f,c,p,m=0,h=0;for(p=0;p<t;p++)h=a**p,f=Math.ceil(i/s/h),c=Math.ceil(n/o/h),m+=f*c;h=a**t,f=Math.ceil(i/s/h),c=Math.ceil(n/o/h),m+=e*f+r,m*=4*l;const u=this._storageIndex.subarray(m,m+4*l);let g=0,d=0;const y=[];for(let x=0;x<l;x++)g=u[4*x]*2**32+u[4*x+1],d=g+u[4*x+2]*2**32+u[4*x+3],y.push({from:g,to:d});return{ranges:y,actualTileWidth:r<f-1?s:Math.ceil(i/h)-s*(f-1),actualTileHeight:e<c-1?o:Math.ceil(n/h)-o*(c-1)}}_parseHeader(t){const r=h(t,"MRF_META/Raster");if(!r)throw new e("mrf:open","not a valid MRF format");const s=h(r,"Size"),n=parseInt(s.getAttribute("x"),10),c=parseInt(s.getAttribute("y"),10),m=parseInt(s.getAttribute("c"),10),g=(u(r,"Compression")||"none").toLowerCase();if(!x.has(g))throw new e("mrf:open","currently does not support compression "+g);const d=u(r,"DataType")||"UInt8",w=y.get(d);if(null==w)throw new e("mrf:open","currently does not support pixel type "+d);const I=h(r,"PageSize"),b=parseInt(I.getAttribute("x"),10),R=parseInt(I.getAttribute("y"),10),A=h(r,"DataValues");let F,_;A&&(_=A.getAttribute("NoData"),null!=_&&(F=_.trim().split(" ").map(t=>parseFloat(t))));if(h(t,"MRF_META/CachedSource"))throw new e("mrf:open","currently does not support MRF referencing other data files");const S=h(t,"MRF_META/GeoTags"),k=h(S,"BoundingBox");let M,j=!1;if(null!=k){const t=parseFloat(k.getAttribute("minx")),e=parseFloat(k.getAttribute("miny")),r=parseFloat(k.getAttribute("maxx")),s=parseFloat(k.getAttribute("maxy")),a=u(S,"Projection")||"";let n=i.WGS84;if("LOCAL_CS[]"!==a)if(a.toLowerCase().startsWith("epsg:")){const t=Number(a.slice(5));isNaN(t)||0===t||(n=new i({wkid:t}))}else n=p(a)??i.WGS84;else j=!0,n=new i({wkid:3857});M=new o(t,e,r,s),M.spatialReference=n}else j=!0,M=new o({xmin:-.5,ymin:.5-c,xmax:n-.5,ymax:.5,spatialReference:new i({wkid:3857})});const C=h(t,"MRF_META/Rsets"),T=parseInt(C?.getAttribute("scale")||"2",10),L=M.spatialReference,U=new f({origin:new a({x:M.xmin,y:M.ymax,spatialReference:L}),blockWidth:b,blockHeight:R,pyramidBlockWidth:b,pyramidBlockHeight:R,compression:g,pyramidScalingFactor:T}),B=new a({x:M.width/n,y:M.height/c,spatialReference:L}),E=new l({width:n,height:c,extent:M,isPseudoSpatialReference:j,spatialReference:L,bandCount:m,pixelType:w,pixelSize:B,noDataValue:F,storageInfo:U}),P=u(t,"datafile"),W=u(t,"IndexFile");return{rasterInfo:E,files:{mrf:this.url,index:W||this.url.replace(".mrf",".idx"),data:P||this.url.replace(".mrf",x.get(g).blobExtension)}}}async _fetchAuxiliaryData(t){try{const{data:e}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:t?.signal});return m(e)}catch{return null}}};function I(t){if(t.byteLength%16>0)throw new Error("invalid array buffer must be multiples of 16");let e,r,s,o,a,i;if(g){for(r=new Uint8Array(t),o=new ArrayBuffer(t.byteLength),s=new Uint8Array(o),a=0;a<t.byteLength/4;a++)for(i=0;i<4;i++)s[4*a+i]=r[4*a+3-i];e=new Uint32Array(o)}else e=new Uint32Array(t);return e}t([r()],w.prototype,"_files",void 0),t([r()],w.prototype,"_storageIndex",void 0),t([r({type:String,json:{write:!0}})],w.prototype,"datasetFormat",void 0),w=t([s("esri.layers.support.rasterDatasets.MRFRaster")],w);const b=w;export{b as default};
5
+ import{_ as t}from"../../../chunks/tslib.es6.js";import e from"../../../core/Error.js";import{property as r}from"../../../core/accessorSupport/decorators/property.js";import"../../../core/has.js";import"../../../core/Logger.js";import"../../../core/RandomLCG.js";import{subclass as s}from"../../../core/accessorSupport/decorators/subclass.js";import o from"../../../geometry/Extent.js";import a from"../../../geometry/Point.js";import i from"../../../geometry/SpatialReference.js";import n from"../PixelBlock.js";import l from"../RasterInfo.js";import f from"../RasterStorageInfo.js";import c from"./BaseRaster.js";import{parseSpatialReference as p,parsePAMInfo as m}from"./pamParser.js";import{getElement as h,getElementValue as u}from"./xmlUtilities.js";import{isPlatformLittleEndian as g}from"../rasterFormats/utils.js";import{estimateStatisticsFromHistograms as d}from"../rasterFunctions/stretchUtils.js";const y=new Map;y.set("Int8","s8"),y.set("UInt8","u8"),y.set("Int16","s16"),y.set("UInt16","u16"),y.set("Int32","s32"),y.set("UInt32","u32"),y.set("Float32","f32"),y.set("Float64","f32"),y.set("Double64","f32");const x=new Map;x.set("none",{blobExtension:".til",isOneSegment:!0,decoderFormat:"bip"}),x.set("lerc",{blobExtension:".lrc",isOneSegment:!1,decoderFormat:"lerc"}),x.set("deflate",{blobExtension:".pzp",isOneSegment:!0,decoderFormat:"deflate"}),x.set("jpeg",{blobExtension:".pjg",isOneSegment:!0,decoderFormat:"jpg"});let w=class extends c{constructor(){super(...arguments),this._files=null,this._storageIndex=null,this.datasetFormat="MRF"}async fetchRawTile(t,e,r,s={}){const{blockWidth:o,blockHeight:a,blockBoundary:i}=this.rasterInfo.storageInfo,l=i[t];if(!l||l.maxRow<e||l.maxCol<r||l.minRow>e||l.minCol>r)return null;const{bandCount:f,pixelType:c}=this.rasterInfo,{ranges:p,actualTileWidth:m,actualTileHeight:h}=this._getTileLocation(t,e,r);if(!p||0===p.length)return null;if(0===p[0].from&&0===p[0].to){const t=new Uint8Array(o*a);return new n({width:o,height:a,pixels:void 0,mask:t,validPixelCount:0})}const{bandIds:u}=this.ioConfig,g=this._getBandSegmentCount(),d=[];let y=0;for(y=0;y<g;y++)u&&!u.includes(y)||d.push(this.request(this._files.data,{range:{from:p[y].from,to:p[y].to},responseType:"array-buffer",signal:s.signal}));const w=await Promise.all(d),I=w.map(t=>t.data.byteLength).reduce((t,e)=>t+e),b=new Uint8Array(I),R=[];let A=0;for(y=0;y<g;y++)R.push(A),b.set(new Uint8Array(w[y].data),A),A+=w[y].data.byteLength;const F=x.get(this.rasterInfo.storageInfo.compression).decoderFormat,_=await this.decodePixelBlock(b.buffer,{width:o,height:a,format:F,planes:u?.length||f,offsets:R,pixelType:c});if(null==_)return null;let{noDataValue:S}=this.rasterInfo;if(null!=S&&"lerc"!==F&&!_.mask&&(S=S[0],null!=S)){const t=_.width*_.height,e=new Uint8Array(t);if(Math.abs(S)>1e24)for(y=0;y<t;y++)Math.abs((_.pixels[0][y]-S)/S)>1e-6&&(e[y]=1);else for(y=0;y<t;y++)_.pixels[0][y]!==S&&(e[y]=1);_.mask=e}let k=0,M=0;if(m!==o||h!==a){let t=_.mask;if(t)for(y=0;y<a;y++)if(M=y*o,y<h)for(k=m;k<o;k++)t[M+k]=0;else for(k=0;k<o;k++)t[M+k]=0;else for(t=new Uint8Array(o*a),_.mask=t,y=0;y<h;y++)for(M=y*o,k=0;k<m;k++)t[M+k]=1}return _}async _open(t){this.datasetName=this.url.slice(this.url.lastIndexOf("/")+1);const e=t?t.signal:null,r=await this.request(this.url,{responseType:"xml",signal:e}),{rasterInfo:s,files:o}=this._parseHeader(r.data),{skipMapInfo:a,skipExtensions:i=[]}=this.ioConfig;if(!i.includes("aux.xml")&&!a){const e=await this._fetchAuxiliaryData(t);null!=e&&(s.statistics=e.statistics??s.statistics,s.histograms=e.histograms,e.histograms&&null==s.statistics&&(s.statistics=d(e.histograms)))}a&&this.updateImageSpaceRasterInfo(s),this._set("rasterInfo",s),this._files=o;const n=await this.request(o.index,{responseType:"array-buffer",signal:e});this._storageIndex=I(n.data);const{blockWidth:l,blockHeight:f}=this.rasterInfo.storageInfo,c=this.rasterInfo.storageInfo.pyramidScalingFactor,{width:p,height:m}=this.rasterInfo,h=[],u=this._getBandSegmentCount();let g=0,y=-1;for(;g<this._storageIndex.length;){y++;const t=Math.ceil(p/l/c**y)-1,e=Math.ceil(m/f/c**y)-1;g+=(t+1)*(e+1)*u*4,h.push({maxRow:e,maxCol:t,minCol:0,minRow:0})}this.rasterInfo.storageInfo.blockBoundary=h,y>0&&(this.rasterInfo.storageInfo.firstPyramidLevel=1,this.rasterInfo.storageInfo.maximumPyramidLevel=y),this.updateTileInfo()}_getBandSegmentCount(){return x.get(this.rasterInfo.storageInfo.compression).isOneSegment?1:this.rasterInfo.bandCount}_getTileLocation(t,e,r){const{blockWidth:s,blockHeight:o,pyramidScalingFactor:a}=this.rasterInfo.storageInfo,{width:i,height:n}=this.rasterInfo,l=this._getBandSegmentCount();let f,c,p,m=0,h=0;for(p=0;p<t;p++)h=a**p,f=Math.ceil(i/s/h),c=Math.ceil(n/o/h),m+=f*c;h=a**t,f=Math.ceil(i/s/h),c=Math.ceil(n/o/h),m+=e*f+r,m*=4*l;const u=this._storageIndex.subarray(m,m+4*l);let g=0,d=0;const y=[];for(let x=0;x<l;x++)g=u[4*x]*2**32+u[4*x+1],d=g+u[4*x+2]*2**32+u[4*x+3]-1,y.push({from:g,to:d});return{ranges:y,actualTileWidth:r<f-1?s:Math.ceil(i/h)-s*(f-1),actualTileHeight:e<c-1?o:Math.ceil(n/h)-o*(c-1)}}_parseHeader(t){const r=h(t,"MRF_META/Raster");if(!r)throw new e("mrf:open","not a valid MRF format");const s=h(r,"Size"),n=parseInt(s.getAttribute("x"),10),c=parseInt(s.getAttribute("y"),10),m=parseInt(s.getAttribute("c"),10),g=(u(r,"Compression")||"none").toLowerCase();if(!x.has(g))throw new e("mrf:open","currently does not support compression "+g);const d=u(r,"DataType")||"UInt8",w=y.get(d);if(null==w)throw new e("mrf:open","currently does not support pixel type "+d);const I=h(r,"PageSize"),b=parseInt(I.getAttribute("x"),10),R=parseInt(I.getAttribute("y"),10),A=h(r,"DataValues");let F,_;A&&(_=A.getAttribute("NoData"),null!=_&&(F=_.trim().split(" ").map(t=>parseFloat(t))));if(h(t,"MRF_META/CachedSource"))throw new e("mrf:open","currently does not support MRF referencing other data files");const S=h(t,"MRF_META/GeoTags"),k=h(S,"BoundingBox");let M,j=!1;if(null!=k){const t=parseFloat(k.getAttribute("minx")),e=parseFloat(k.getAttribute("miny")),r=parseFloat(k.getAttribute("maxx")),s=parseFloat(k.getAttribute("maxy")),a=u(S,"Projection")||"";let n=i.WGS84;if("LOCAL_CS[]"!==a)if(a.toLowerCase().startsWith("epsg:")){const t=Number(a.slice(5));isNaN(t)||0===t||(n=new i({wkid:t}))}else n=p(a)??i.WGS84;else j=!0,n=new i({wkid:3857});M=new o(t,e,r,s),M.spatialReference=n}else j=!0,M=new o({xmin:-.5,ymin:.5-c,xmax:n-.5,ymax:.5,spatialReference:new i({wkid:3857})});const C=h(t,"MRF_META/Rsets"),T=parseInt(C?.getAttribute("scale")||"2",10),L=M.spatialReference,U=new f({origin:new a({x:M.xmin,y:M.ymax,spatialReference:L}),blockWidth:b,blockHeight:R,pyramidBlockWidth:b,pyramidBlockHeight:R,compression:g,pyramidScalingFactor:T}),B=new a({x:M.width/n,y:M.height/c,spatialReference:L}),E=new l({width:n,height:c,extent:M,isPseudoSpatialReference:j,spatialReference:L,bandCount:m,pixelType:w,pixelSize:B,noDataValue:F,storageInfo:U}),P=u(t,"datafile"),W=u(t,"IndexFile");return{rasterInfo:E,files:{mrf:this.url,index:W||this.url.replace(".mrf",".idx"),data:P||this.url.replace(".mrf",x.get(g).blobExtension)}}}async _fetchAuxiliaryData(t){try{const{data:e}=await this.request(this.url+".aux.xml",{responseType:"xml",signal:t?.signal});return m(e)}catch{return null}}};function I(t){if(t.byteLength%16>0)throw new Error("invalid array buffer must be multiples of 16");let e,r,s,o,a,i;if(g){for(r=new Uint8Array(t),o=new ArrayBuffer(t.byteLength),s=new Uint8Array(o),a=0;a<t.byteLength/4;a++)for(i=0;i<4;i++)s[4*a+i]=r[4*a+3-i];e=new Uint32Array(o)}else e=new Uint32Array(t);return e}t([r()],w.prototype,"_files",void 0),t([r()],w.prototype,"_storageIndex",void 0),t([r({type:String,json:{write:!0}})],w.prototype,"datasetFormat",void 0),w=t([s("esri.layers.support.rasterDatasets.MRFRaster")],w);const b=w;export{b as default};