@arcgis/core 4.25.0-next.20221021 → 4.25.0-next.20221023

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 (66) hide show
  1. package/WebMap.js +1 -1
  2. package/arcade.js +1 -1
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/{0b0f3e93f658a012d5f0.js → 00df1053d3a8761fc0a3.js} +1 -1
  5. package/assets/esri/core/workers/chunks/0de7eca7acf74947cf2e.js +1 -0
  6. package/assets/esri/core/workers/chunks/{2474f0e8b8abc1387106.js → 2600954826b42f2b70c4.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{af3f30f968363bb3930c.js → 353c4a51be72c4a77e1f.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{2d8201f0f33ba66bb96b.js → 5f46751fa500a9dfacf9.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{b9e93d9ea80361716f1d.js → 64190294f3dc9237b420.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{883cfe319b15ebabf71e.js → 73ad8f3d3feff5882988.js} +1 -1
  11. package/assets/esri/core/workers/chunks/{177c8d5e2531c6f64581.js → 796504f93100aea7c6f5.js} +1 -1
  12. package/assets/esri/core/workers/chunks/8435ae4fe5a5332b1076.js +1 -0
  13. package/assets/esri/core/workers/chunks/{c8c0f091aab41e4effa5.js → 85690fabbfe60681f5e7.js} +1 -1
  14. package/assets/esri/core/workers/chunks/{942da417257f8fd8e4cf.js → 858970a88406562a26cc.js} +1 -1
  15. package/assets/esri/core/workers/chunks/a17d20ffaa47d430d98c.js +1 -0
  16. package/assets/esri/core/workers/chunks/ac2903c5f1587dec2f80.js +1 -0
  17. package/assets/esri/core/workers/chunks/{7ba0cfe4d1c214f44fc7.js → b6d9750b16bbf8ce5307.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{7f40f4ac6e2af4b333f5.js → c4e5b929b152f8d36cc3.js} +1 -1
  19. package/assets/esri/core/workers/chunks/c7de993c0a85594a1969.js +1 -0
  20. package/assets/esri/core/workers/chunks/ca92022f53080fda75fe.js +1 -0
  21. package/assets/esri/core/workers/chunks/d7668e81467833a5a53d.js +1 -0
  22. package/assets/esri/core/workers/chunks/de83b062359c0459585f.js +1 -0
  23. package/assets/esri/core/workers/chunks/f57c3343f93d87423856.js +1 -0
  24. package/assets/esri/core/workers/chunks/f704ed07c514a0f436ec.js +1 -0
  25. package/assets/esri/themes/base/_color.scss +1 -0
  26. package/assets/esri/themes/base/widgets/_BasemapLayerList.scss +58 -14
  27. package/assets/esri/themes/base/widgets/_LayerList.scss +57 -13
  28. package/assets/esri/themes/dark/main.css +1 -1
  29. package/assets/esri/themes/light/main.css +1 -1
  30. package/assets/esri/themes/light/view.css +1 -1
  31. package/geometry/support/normalizeUtils.js +1 -1
  32. package/interfaces.d.ts +109 -6
  33. package/package.json +1 -1
  34. package/support/revision.js +1 -1
  35. package/symbols/cim/CIMSymbolHelper.js +1 -1
  36. package/symbols/cim/Rasterizer.js +1 -1
  37. package/symbols/cim/rasterizingUtils.js +5 -0
  38. package/views/2d/engine/brushes.js +1 -1
  39. package/views/2d/engine/vectorTiles/SpriteMosaic.js +1 -1
  40. package/views/2d/engine/vectorTiles/VTLPainter3D.js +1 -1
  41. package/views/2d/engine/vectorTiles/style/StyleLayer.js +1 -1
  42. package/views/2d/engine/vtlBrushes.js +5 -0
  43. package/views/2d/engine/webgl/mesh/bufcut.js +1 -1
  44. package/views/2d/layers/features/schemaUtils.js +1 -1
  45. package/widgets/BasemapLayerList/BasemapLayerListViewModel.js +1 -1
  46. package/widgets/BasemapLayerList.js +1 -1
  47. package/widgets/Feature/FeatureExpression/FeatureExpressionViewModel.js +1 -1
  48. package/widgets/FeatureForm/FormExpressionArcadeExecutor.js +1 -1
  49. package/widgets/FeatureForm/FormExpressionsManager.js +1 -1
  50. package/widgets/FeatureForm.js +1 -1
  51. package/widgets/LayerList/LayerListViewModel.js +1 -1
  52. package/widgets/LayerList/ListItem.js +1 -1
  53. package/widgets/LayerList.js +1 -1
  54. package/widgets/UtilityNetworkTrace.js +1 -1
  55. package/assets/esri/core/workers/chunks/0cfb97b9f38c31b3b33a.js +0 -1
  56. package/assets/esri/core/workers/chunks/2a63949c3aad9ace1b44.js +0 -1
  57. package/assets/esri/core/workers/chunks/3b5be512567d9c1c6fe6.js +0 -1
  58. package/assets/esri/core/workers/chunks/4450f17444947fe2f27f.js +0 -1
  59. package/assets/esri/core/workers/chunks/5abda500f5d5607155ab.js +0 -1
  60. package/assets/esri/core/workers/chunks/81139c01e8016cbbe324.js +0 -1
  61. package/assets/esri/core/workers/chunks/94027976cfca4ad5789b.js +0 -1
  62. package/assets/esri/core/workers/chunks/9d410721f42259efe666.js +0 -1
  63. package/assets/esri/core/workers/chunks/b17ff3dfdc638f9f5705.js +0 -1
  64. package/assets/esri/core/workers/chunks/d6eb078d94171fb9d3d4.js +0 -1
  65. package/rest/geometry/cut.js +0 -5
  66. package/rest/geometry/simplify.js +0 -5
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4028],{17445:(e,t,i)=>{i.d(t,{N1:()=>d,YP:()=>l,Z_:()=>y,gx:()=>u,nn:()=>f,on:()=>c,tX:()=>g});var r=i(91460),n=i(50758),s=i(70586),o=i(95330),a=i(26258);function l(e,t,i={}){return p(e,t,i,m)}function u(e,t,i={}){return p(e,t,i,h)}function p(e,t,i={},r){let n=null;const o=i.once?(e,i)=>{r(e)&&((0,s.hw)(n),t(e,i))}:(e,i)=>{r(e)&&t(e,i)};if(n=(0,a.aQ)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return n}function c(e,t,i,o={}){let a=null,u=null,p=null;function c(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function d(e){o.once&&o.once&&(0,s.hw)(p),i(e)}const m=l(e,((e,i)=>{c(),(0,r.vT)(e)&&(a=e,u=(0,r.on)(e,t,d),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return p=(0,n.kB)((()=>{m.remove(),c()})),p}function d(e,t){return function(e,t,i){if((0,o.Hc)(i))return Promise.reject((0,o.zE)());const r=e();if(t?.(r))return Promise.resolve(r);let a=null;function l(){a=(0,s.hw)(a)}return new Promise(((r,s)=>{a=(0,n.AL)([(0,o.fu)(i,(()=>{l(),s((0,o.zE)())})),p(e,(e=>{l(),r(e)}),{sync:!1,once:!0},t??m)])}))}(e,h,t)}function m(e){return!0}function h(e){return!!e}i(87538);const y={sync:!0},f={initial:!0},g={sync:!0,initial:!0}},66210:(e,t,i)=>{i.r(t),i.d(t,{default:()=>bt});var r=i(43697),n=i(51773),s=i(70586),o=i(16453),a=i(95330),l=i(5600),u=(i(67676),i(75215)),p=i(52011),c=i(30556),d=i(87085),m=i(66577),h=i(38171),y=i(30030),f=i(3172),g=i(20102),b=i(35454),R=i(22974),v=i(92604),w=i(17445),_=i(17452),C=i(71715),S=i(21506),x=i(35956),I=i(96674),F=i(40297);const T={StretchFunction:{arguments:{ComputeGamma:{isDataset:!1,isPublic:!1,name:"ComputeGamma",type:"RasterFunctionVariable",value:!1},DRA:{isDataset:!1,isPublic:!1,name:"DRA",type:"RasterFunctionVariable",value:!1},EstimateStatsHistogram:{isDataset:!1,isPublic:!1,name:"EstimateStatsHistogram",type:"RasterFunctionVariable",value:!1},Gamma:{displayName:"Gamma",isDataset:!1,isPublic:!1,name:"Gamma",type:"RasterFunctionVariable"},Histograms:{isDataset:!1,isPublic:!1,name:"Histograms",type:"RasterFunctionVariable"},Max:{isDataset:!1,isPublic:!1,name:"Max",type:"RasterFunctionVariable",value:255},MaxPercent:{isDataset:!1,isPublic:!1,name:"MaxPercent",type:"RasterFunctionVariable",value:.5},Min:{isDataset:!1,isPublic:!1,name:"Min",type:"RasterFunctionVariable",value:0},MinPercent:{isDataset:!1,isPublic:!1,name:"MinPercent",type:"RasterFunctionVariable",value:.25},NumberOfStandardDeviations:{isDataset:!1,isPublic:!1,name:"NumberOfStandardDeviation",type:"RasterFunctionVariable",value:2},Raster:{isDataset:!0,isPublic:!1,name:"Raster",type:"RasterFunctionVariable"},SigmoidStrengthLevel:{isDataset:!1,isPublic:!1,name:"SigmoidStrengthLevel",type:"RasterFunctionVariable",value:2},Statistics:{isDataset:!1,isPublic:!1,name:"Statistics",type:"RasterFunctionVariable"},StretchType:{isDataset:!1,isPublic:!1,name:"StretchType",type:"RasterFunctionVariable",value:0},type:"StretchFunctionArguments",UseGamma:{isDataset:!1,isPublic:!1,name:"UseGamma",type:"RasterFunctionVariable",value:!1}},description:"Enhances an image by adjusting the range of values displayed. This does not alter the underlying pixel values. If a pixel has a value outside of the specified range, it will appear as either the minimum or maximum value.",function:{description:"Enhances an image by adjusting the range of values displayed. This does not alter the underlying pixel values. If a pixel has a value outside of the specified range, it will appear as either the minimum or maximum value.",name:"Stretch",pixelType:"UNKNOWN",type:"StretchFunction"},functionType:0,name:"Stretch",thumbnail:""},RemapFunction:{name:"Remap",description:"Changes pixel values by assigning new values to ranges of pixel values or using an external table.",function:{type:"RemapFunction",pixelType:"UNKNOWN",name:"Remap",description:"Changes pixel values by assigning new values to ranges of pixel values or using an external table."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},UseTable:{name:"UseTable",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},InputRanges:{name:"InputRanges",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"Input Ranges"},OutputValues:{name:"OutputValues",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"Output Values"},NoDataRanges:{name:"NoDataRanges",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"NoData Ranges"},Table:{name:"Table",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},InputField:{name:"InputField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},OutputField:{name:"OutputField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},InputMaxField:{name:"InputMaxField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},RemapTableType:{name:"RemapTableType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},AllowUnmatched:{name:"AllowUnmatched",isPublic:!1,isDataset:!1,value:!0,type:"RasterFunctionVariable"},type:"RemapFunctionArguments"},functionType:0,thumbnail:""},ColormapFunction:{name:"Colormap",description:"Changes pixel values to display the raster data as either a grayscale or a red, green, blue (RGB) image, based on a colormap or a color ramp.",function:{type:"ColormapFunction",pixelType:"UNKNOWN",name:"Colormap",description:"Changes pixel values to display the raster data as either a grayscale or a red, green, blue (RGB) image, based on a colormap or a color ramp."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ColorSchemeType:{name:"ColorSchemeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},Colormap:{name:"Colormap",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},ColormapName:{name:"ColormapName",isPublic:!1,isDataset:!1,value:"Gray",type:"RasterFunctionVariable"},ColorRamp:{name:"ColorRamp",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},type:"ColormapFunctionArguments"},functionType:0,thumbnail:""},ShadedReliefFunction:{name:"Shaded Relief",description:"Creates a multiband, color coded, 3D representation of the surface, with the sun's relative position taken into account for shading the image.",function:{type:"ShadedReliefFunction",pixelType:"UNKNOWN",name:"Shaded Relief",description:"Creates a multiband, color coded, 3D representation of the surface, with the sun's relative position taken into account for shading the image."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ColorSchemeType:{name:"ColorSchemeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ColorRamp:{name:"ColorRamp",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},HillshadeType:{name:"HillshadeType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},Colormap:{name:"Colormap",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},Azimuth:{name:"Azimuth",isPublic:!1,isDataset:!1,value:315,type:"RasterFunctionVariable"},Altitude:{name:"Altitude",isPublic:!1,isDataset:!1,value:45,type:"RasterFunctionVariable"},SlopeType:{name:"SlopeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ZFactor:{name:"ZFactor",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},PSPower:{name:"PSPower",isPublic:!1,isDataset:!1,value:.664,type:"RasterFunctionVariable"},PSZFactor:{name:"PSZFactor",isPublic:!1,isDataset:!1,value:.024,type:"RasterFunctionVariable"},RemoveEdgeEffect:{name:"RemoveEdgeEffect",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},type:"ShadedReliefFunctionArguments"},functionType:0,thumbnail:""},HillshadeFunction:{name:"Hillshade",description:"Creates a 3D representation of the surface, with the sun's relative position taken into account for shading the image",function:{type:"HillshadeFunction",pixelType:"UNKNOWN",name:"Hillshade",description:"Creates a 3D representation of the surface, with the sun's relative position taken into account for shading the image"},arguments:{DEM:{name:"DEM",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},HillshadeType:{name:"HillshadeType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},Azimuth:{name:"Azimuth",isPublic:!1,isDataset:!1,value:315,type:"RasterFunctionVariable"},Altitude:{name:"Altitude",isPublic:!1,isDataset:!1,value:45,type:"RasterFunctionVariable"},SlopeType:{name:"SlopeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ZFactor:{name:"ZFactor",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},PSPower:{name:"PSPower",isPublic:!1,isDataset:!1,value:.664,type:"RasterFunctionVariable"},PSZFactor:{name:"PSZFactor",isPublic:!1,isDataset:!1,value:.024,type:"RasterFunctionVariable"},RemoveEdgeEffect:{name:"RemoveEdgeEffect",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},type:"HillshadeFunctionArguments"},functionType:0,thumbnail:""},ResampleFunction:{name:"Resample",description:"Changes the cell size of a raster.",function:{type:"ResampleFunction",pixelType:"UNKNOWN",name:"Resample",description:"Changes the cell size of a raster."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ResamplingType:{name:"ResamplingType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},InputCellSize:{name:"InputCellsize",isPublic:!1,isDataset:!1,value:{x:0,y:0},type:"RasterFunctionVariable"},OutputCellSize:{name:"OutputCellsize",isPublic:!1,isDataset:!1,value:{x:0,y:0},type:"RasterFunctionVariable"},type:"ResampleFunctionArguments"},functionType:0,thumbnail:""}};var N=i(93010),D=i(75509),j=i(23847);const P={u1:[0,1],u2:[0,3],u4:[0,15],u8:[0,255],s8:[-128,127],u16:[0,65535],s16:[-32768,32767]},O={simple_scalar:"Simple Scalar",wind_barb:"Wind Barb",single_arrow:"Single Arrow",beaufort_kn:"Beaufort Wind (Knots)",beaufort_m:"Beaufort Wind (MetersPerSecond)",ocean_current_m:"Ocean Current (MetersPerSecond)",ocean_current_kn:"Ocean Current (Knots)"},M=new Set(["raster-stretch","unique-value","class-breaks","raster-shaded-relief","vector-field","raster-colormap"]);function V(e){return M.has(e.type)}function A(e,t){if(!e||!t)return(0,R.d9)(e||t);const i=(0,R.d9)(e);if(t.rasterFunctionDefinition){const e=t.rasterFunctionDefinition;(e.thumbnail||e.thumbnailEx)&&(e.thumbnail=e.thumbnailEx=null),J(i.rasterFunctionDefinition.arguments,t)}else"none"!==t.functionName.toLowerCase()&&(E(i.functionArguments).Raster=t);return i}function J(e,t){for(const i in e)"raster"===i.toLowerCase()&&("RasterFunctionVariable"===e[i].type?(e[i]=t.rasterFunctionDefinition,e[i].type="RasterFunctionTemplate"):"RasterFunctionTemplate"===e[i].type&&J(e[i].arguments,t))}function Z(e){const t=(0,R.d9)(T[e.functionName+"Function"]),i=e.functionArguments;for(const e in i)"raster"===e.toLowerCase()?(t.arguments[e]=Z(i[e]),t.arguments[e].type="RasterFunctionTemplate"):"colormap"===e.toLowerCase()?(t.arguments[e].value=k(i[e]),t.arguments.ColorSchemeType.value=0):t.arguments[e].value=i[e];return t}function E(e){const t=e?.Raster;return t&&"esri.layers.support.RasterFunction"===t.declaredClass?E(t.functionArguments):e}const q={none:0,standardDeviation:3,histogramEqualization:4,minMax:5,percentClip:6,sigmoid:9};function z(e,t){const i=P[String(t).toLowerCase()];return i&&e.push([Math.floor(i[0]-1),0,0,0],[Math.ceil(i[1]+1),0,0,0]),e}function L(e){if((0,s.Wi)(e))return;const{fields:t}=e,i=t&&t.find((e=>e&&e.name&&"value"===e.name.toLowerCase()));return i&&i.name}function H(e){const t=[];return e.forEach((e=>{const i=e;if(Array.isArray(i))t.push(i);else{if(null==i.min||null==i.max)return;const e=[i.min,i.max,i.avg||0,i.stddev||0];t.push(e)}})),t}function k(e){const t=[],i=[];return e.forEach((e=>{t.push(e[0]),i.push((0,N.io)([...e.slice(1),255]))})),{type:"RasterColormap",values:t,colors:i}}var B,G=i(90578),Q=i(94139);const U=(0,b.w)()({MT_FIRST:"first",MT_LAST:"last",MT_MIN:"min",MT_MAX:"max",MT_MEAN:"mean",MT_BLEND:"blend",MT_SUM:"sum"}),W=(0,b.w)()({esriMosaicNone:"none",esriMosaicCenter:"center",esriMosaicNadir:"nadir",esriMosaicViewpoint:"viewpoint",esriMosaicAttribute:"attribute",esriMosaicLockRaster:"lock-raster",esriMosaicNorthwest:"northwest",esriMosaicSeamline:"seamline"});let $=B=class extends I.wq{constructor(e){super(e),this.ascending=!0,this.itemRenderingRule=null,this.lockRasterIds=null,this.method=null,this.multidimensionalDefinition=null,this.objectIds=null,this.operation=null,this.sortField=null,this.sortValue=null,this.viewpoint=null,this.where=null}readAscending(e,t){return null!=t.ascending?t.ascending:null==t.sortAscending||t.sortAscending}readMethod(e,t){return function(e){let t;switch(e?e.toLowerCase().replace("esrimosaic",""):""){case"byattribute":case"attribute":t="esriMosaicAttribute";break;case"lockraster":t="esriMosaicLockRaster";break;case"center":t="esriMosaicCenter";break;case"northwest":t="esriMosaicNorthwest";break;case"nadir":t="esriMosaicNadir";break;case"viewpoint":t="esriMosaicViewpoint";break;case"seamline":t="esriMosaicSeamline";break;default:t="esriMosaicNone"}return W.fromJSON(t)}(t.mosaicMethod||t.defaultMosaicMethod)}readOperation(e,t){const i=t.mosaicOperation,r=t.mosaicOperator&&t.mosaicOperator.toLowerCase(),n=i||(r?U.toJSON(r):null);return U.fromJSON(n)||"first"}castSortValue(e){return null==e||"string"==typeof e||"number"==typeof e?e:`${e}`}clone(){return new B({ascending:this.ascending,itemRenderingRule:(0,R.d9)(this.itemRenderingRule),lockRasterIds:(0,R.d9)(this.lockRasterIds),method:this.method,multidimensionalDefinition:(0,R.d9)(this.multidimensionalDefinition),objectIds:(0,R.d9)(this.objectIds),operation:this.operation,sortField:this.sortField,sortValue:this.sortValue,viewpoint:(0,R.d9)(this.viewpoint),where:this.where})}};(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],$.prototype,"ascending",void 0),(0,r._)([(0,C.r)("ascending",["ascending","sortAscending"])],$.prototype,"readAscending",null),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],$.prototype,"itemRenderingRule",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{write:{overridePolicy(){return{enabled:"lock-raster"===this.method}}}}})],$.prototype,"lockRasterIds",void 0),(0,r._)([(0,l.Cb)({type:String,json:{type:W.jsonValues,write:{target:"mosaicMethod",writer:W.write}}})],$.prototype,"method",void 0),(0,r._)([(0,C.r)("method",["mosaicMethod","defaultMosaicMethod"])],$.prototype,"readMethod",null),(0,r._)([(0,l.Cb)({type:[x.Z],json:{write:!0}})],$.prototype,"multidimensionalDefinition",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{name:"fids",write:!0}})],$.prototype,"objectIds",void 0),(0,r._)([(0,l.Cb)({json:{type:U.jsonValues,read:{reader:U.read},write:{target:"mosaicOperation",writer:U.write}}})],$.prototype,"operation",void 0),(0,r._)([(0,C.r)("operation",["mosaicOperation","mosaicOperator"])],$.prototype,"readOperation",null),(0,r._)([(0,l.Cb)({type:String,json:{write:{overridePolicy(){return{enabled:"attribute"===this.method}}}}})],$.prototype,"sortField",void 0),(0,r._)([(0,l.Cb)({type:[String,Number],json:{write:{allowNull:!0,overridePolicy(){return{enabled:"attribute"===this.method,allowNull:!0}}}}})],$.prototype,"sortValue",void 0),(0,r._)([(0,G.p)("sortValue")],$.prototype,"castSortValue",null),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],$.prototype,"viewpoint",void 0),(0,r._)([(0,l.Cb)({type:String,json:{write:!0}})],$.prototype,"where",void 0),$=B=(0,r._)([(0,p.j)("esri.layers.support.MosaicRule")],$);const K=$;var X=i(69608);let Y=class extends I.wq{constructor(){super(...arguments),this.layer=null,this.adjustAspectRatio=void 0,this.compression=void 0,this.pixelType=void 0,this.lercVersion=2}writeAdjustAspectRatio(e,t,i){this.layer.version<10.3||(t[i]=e)}get bandIds(){return this.layer.bandIds}set bandIds(e){this.layer&&(this.layer.bandIds=e)}get compressionQuality(){return this.layer?.compressionQuality}set compressionQuality(e){this.layer&&(this.layer.compressionQuality=e)}writeCompressionQuality(e,t,i){this.format&&this.format.toLowerCase().includes("jpg")&&null!=e&&(t[i]=e)}get compressionTolerance(){return this.layer?.compressionTolerance}set compressionTolerance(e){this.layer&&(this.layer.compressionTolerance=e)}writeCompressionTolerance(e,t,i){"lerc"===this.format&&null!=e&&(t[i]=e)}get format(){return"vector-field"===this.layer.renderer?.type?"lerc":this.layer.format}get interpolation(){return this.layer?.interpolation}set interpolation(e){this.layer&&(this.layer.interpolation=e)}get noData(){return this.layer?.noData}set noData(e){this.layer&&(this.layer.noData=e)}get noDataInterpretation(){return this.layer?.noDataInterpretation}set noDataInterpretation(e){this.layer&&(this.layer.noDataInterpretation=e)}writeLercVersion(e,t,i){"lerc"===this.format&&this.layer.version>=10.5&&(t[i]=e)}get version(){const e=this.layer;return e.commitProperty("bandIds"),e.commitProperty("format"),e.commitProperty("compressionQuality"),e.commitProperty("compressionTolerance"),e.commitProperty("interpolation"),e.commitProperty("noData"),e.commitProperty("noDataInterpretation"),e.commitProperty("mosaicRule"),e.commitProperty("renderingRule"),e.commitProperty("adjustAspectRatio"),e.commitProperty("pixelFilter"),e.commitProperty("definitionExpression"),e.commitProperty("multidimensionalSubset"),(this._get("version")||0)+1}set version(e){this._set("version",e)}get mosaicRule(){const e=this.layer;let t=e.mosaicRule;const i=e.definitionExpression;return t?i&&i!==t.where&&(t=t.clone(),t.where=i):i&&(t=new K({where:i})),t}get renderingRule(){const e=this.layer;let t=e.renderingRule;const i=e.pixelFilter,r=!e.format||e.format.includes("jpg")||e.format.includes("png");t=this._addResampleRasterFunction(t);const n=e.multidimensionalSubset?.areaOfInterest;return n&&(t=this._addClipFunction(t,n)),r&&!i&&"vector-field"!==e.renderer?.type&&(t=this.combineRendererWithRenderingRule(t)),t}combineRendererWithRenderingRule(e){const t=this.layer,{rasterInfo:i,renderer:r}=t;return e=e||t.renderingRule,r&&V(r)?A(function(e,t){switch(t=t||{},e.type){case"raster-stretch":return function(e,t){const i=t.convertToRFT,r=new F.Z;r.functionName="Stretch";const n=q[D.v.toJSON(e.stretchType)],s="u8",o={StretchType:n,Statistics:H(e.statistics),DRA:e.dynamicRangeAdjustment,UseGamma:e.useGamma,Gamma:e.gamma,ComputeGamma:e.computeGamma};if(null!=e.outputMin&&(o.Min=e.outputMin),null!=e.outputMax&&(o.Max=e.outputMax),n===q.standardDeviation?(o.NumberOfStandardDeviations=e.numberOfStandardDeviations,r.outputPixelType=s):n===q.percentClip?(o.MinPercent=e.minPercent,o.MaxPercent=e.maxPercent,r.outputPixelType=s):n===q.minMax?r.outputPixelType=s:n===q.sigmoid&&(o.SigmoidStrengthLevel=e.sigmoidStrengthLevel),r.functionArguments=o,r.variableName="Raster",e.colorRamp){const n=e.colorRamp,s=new F.Z;if(i)s.functionArguments={ColorRamp:(0,N.pM)(n)};else{const i=(0,N.Uh)(n);if(i)s.functionArguments={colorRamp:i};else if(!t.convertColorRampToColormap||"algorithmic"!==n.type&&"multipart"!==n.type){const t=e.colorRamp.toJSON();"algorithmic"===t.type?t.algorithm=t.algorithm||"esriCIELabAlgorithm":"multipart"===t.type&&t.colorRamps?.length&&t.colorRamps.forEach((e=>e.algorithm=e.algorithm||"esriCIELabAlgorithm")),s.functionArguments={colorRamp:t}}else s.functionArguments={Colormap:(0,N.Jw)(n,256)}}return s.variableName="Raster",s.functionName="Colormap",s.functionArguments.Raster=r,i?new F.Z({rasterFunctionDefinition:Z(s)}):s}return i?new F.Z({rasterFunctionDefinition:Z(r)}):r}(e,t);case"class-breaks":return function(e,t){const i=[],r=[],n=[],o=[],a=1e-6,{pixelType:l,rasterAttributeTable:u}=t,p=(0,s.Wi)(u)?null:u.features,c=L(u);if(p&&Array.isArray(p)&&e.classBreakInfos){e.classBreakInfos.forEach(((t,i)=>{const r=t.symbol.color;let n;r.a&&p.forEach((s=>{n=s.attributes[e.field],(n>=t.minValue&&n<t.maxValue||i===e.classBreakInfos.length-1&&n>=t.minValue)&&o.push([s.attributes[c],r.r,r.g,r.b])}))}));const i=l?z(o,l):o,r=new F.Z;return r.functionName="Colormap",r.functionArguments={},r.functionArguments.Colormap=i,r.variableName="Raster",t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(r)}):r}e.classBreakInfos.forEach(((e,t)=>{const s=e.symbol&&e.symbol.color;s.a?(0===t?i.push(e.minValue,e.maxValue+a):i.push(e.minValue+a,e.maxValue+a),r.push(t),o.push([t,s.r,s.g,s.b])):n.push(e.minValue,e.maxValue)}));const d=l?z(o,l):o,m=new F.Z;m.functionName="Remap",m.functionArguments={InputRanges:i,OutputValues:r,NoDataRanges:n},m.variableName="Raster";const h=new F.Z;return h.functionName="Colormap",h.functionArguments={Colormap:d,Raster:m},t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(h)}):h}(e,t);case"unique-value":return function(e,t){const i=[],{pixelType:r,rasterAttributeTable:n}=t,o=(0,s.Wi)(n)?null:n.features,a=L(n),l=e.defaultSymbol?.color?.toRgb(),u=e.uniqueValueInfos;if(u)if(o){const t=new Map;u.forEach((e=>{const i=e.value,r=e.symbol.color;null!=i&&r&&r.a&&t.set(String(i),r.toRgb())}));const r=e.field;o.forEach((({attributes:e})=>{const n=String(e[r]),s=e[a];if(t.has(n)){const e=t.get(n);i.push([s,...e])}else l&&i.push([s,...l])}))}else for(let e=0;e<u.length;e++){const t=u[e],r=t.symbol.color,n=+t.value;if(r?.a){if(isNaN(n))return null;i.push([n,r.r,r.g,r.b])}}const p=r&&i.length>0?z(i,r):i,c=new F.Z;return c.functionName="Colormap",c.functionArguments={},c.functionArguments.Colormap=p,c.variableName="Raster",t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(c)}):c}(e,t);case"raster-colormap":return function(e,t){const i=e.extractColormap();if(!i||0===i.length)return;const{pixelType:r}=t,n=r?z(i,r):i,s=new F.Z;return s.functionName="Colormap",s.functionArguments={},s.functionArguments.Colormap=n,t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(s)}):s}(e,t);case"vector-field":return function(e,t){const i=new F.Z;i.functionName="VectorFieldRenderer";const{dataType:r,bandProperties:n}=t,s="vector-uv"===r;let o,a;n&&2===n.length&&(o=n.map((e=>e.BandName.toLowerCase())).indexOf("magnitude"),a=n.map((e=>e.BandName.toLowerCase())).indexOf("direction")),-1!==o&&null!==o||(o=0,a=1);const l="arithmetic"===e.rotationType?1:2,u="flow-from"===e.flowRepresentation?0:1,p=e.visualVariables?e.visualVariables.find((e=>"Magnitude"===e.field)):new j.Z,c={magnitudeBandID:o,directionBandID:a,isUVComponents:s,referenceSystem:l,massFlowAngleRepresentation:u,symbolTileSize:50,symbolTileSizeUnits:100,calculationMethod:"Vector Average",symbologyName:O[e.style.toLowerCase().replace("-","_")],minimumMagnitude:p.minDataValue,maximumMagnitude:p.maxDataValue,minimumSymbolSize:p.minSize,maximumSymbolSize:p.maxSize};return i.functionArguments=c,t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(i)}):i}(e,t);case"raster-shaded-relief":return function(e,t){const i=t.convertToRFT;if("elevation"!==t.dataType&&("generic"!==t.dataType||1!==t.bandCount||"s16"!==t.pixelType&&"s32"!==t.pixelType&&"f32"!==t.pixelType&&"f64"!==t.pixelType))return new F.Z;const r=new F.Z;r.functionName="Hillshade";const n="traditional"===e.hillshadeType?0:1,s="none"===e.scalingType?1:3,o={HillshadeType:n,SlopeType:s,ZFactor:e.zFactor};return 0===n&&(o.Azimuth=e.azimuth,o.Altitude=e.altitude),3===s&&(o.PSPower=e.pixelSizePower,o.PSZFactor=e.pixelSizeFactor),r.functionArguments=o,r.variableName="Raster",e.colorRamp&&(r.functionName="ShadedRelief",i?o.ColorRamp=(0,N.pM)(e.colorRamp):o.Colormap=(0,N.Jw)(e.colorRamp,256)),i?new F.Z({rasterFunctionDefinition:Z(r)}):r}(e,t);case"flow":throw new Error("Unsupported rendering rule.")}}(r,{rasterAttributeTable:i.attributeTable,pixelType:i.pixelType,dataType:i.dataType,bandProperties:i.keyProperties?.BandProperties,convertColorRampToColormap:t.version<10.6,convertToRFT:!!e?.rasterFunctionDefinition,bandCount:i.bandCount}),e):e}_addResampleRasterFunction(e){if("vector-field"!==this.layer.renderer?.type||"Resample"===e?.functionName)return e;const t="esriImageServiceDataTypeVector-UV"===this.layer.serviceDataType?7:10,i=this.layer.serviceRasterInfo.pixelSize;let r=new F.Z({functionName:"Resample",functionArguments:{ResamplingType:t,InputCellSize:i}});return r=e?.rasterFunctionDefinition?new F.Z({rasterFunctionDefinition:Z(r)}):r,A(r,e)}_addClipFunction(e,t){return A(new F.Z({functionName:"Clip",functionArguments:{ClippingGeometry:t.toJSON(),ClippingType:1}}),e)}};(0,r._)([(0,l.Cb)()],Y.prototype,"layer",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"adjustAspectRatio",void 0),(0,r._)([(0,c.c)("adjustAspectRatio")],Y.prototype,"writeAdjustAspectRatio",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"bandIds",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compression",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compressionQuality",null),(0,r._)([(0,c.c)("compressionQuality")],Y.prototype,"writeCompressionQuality",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compressionTolerance",null),(0,r._)([(0,c.c)("compressionTolerance")],Y.prototype,"writeCompressionTolerance",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"format",null),(0,r._)([(0,l.Cb)({type:String,json:{read:{reader:X.c.read},write:{writer:X.c.write}}})],Y.prototype,"interpolation",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"noData",null),(0,r._)([(0,l.Cb)({type:String,json:{read:{reader:X.k.read},write:{writer:X.k.write}}})],Y.prototype,"noDataInterpretation",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"pixelType",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"lercVersion",void 0),(0,r._)([(0,c.c)("lercVersion")],Y.prototype,"writeLercVersion",null),(0,r._)([(0,l.Cb)({type:Number})],Y.prototype,"version",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"mosaicRule",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"renderingRule",null),Y=(0,r._)([(0,p.j)("esri.layers.mixins.ExportImageServiceParameters")],Y);var ee=i(1231),te=i(99514),ie=i(29876),re=i(5847),ne=i(48526),se=i(88281),oe=i(99815),ae=i(75993),le=i(80676),ue=i(67058),pe=i(72758),ce=i(82526),de=i(11282),me=i(82971);let he=class extends I.wq{constructor(){super(...arguments),this.north=null,this.up=null,this.spatialReference=null}};(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],he.prototype,"north",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],he.prototype,"up",void 0),(0,r._)([(0,l.Cb)({type:me.Z,json:{write:!0}})],he.prototype,"spatialReference",void 0),he=(0,r._)([(0,p.j)("esri.rest.support.ImageAngleResult")],he);const ye=he;var fe=i(74889);let ge=class extends I.wq{constructor(){super(...arguments),this.catalogItemVisibilities=null,this.catalogItems=null,this.location=null,this.name=null,this.objectId=null,this.processedValues=null,this.properties=null,this.value=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"catalogItemVisibilities",void 0),(0,r._)([(0,l.Cb)({type:fe.default,json:{write:!0}})],ge.prototype,"catalogItems",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],ge.prototype,"location",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"name",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"objectId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"processedValues",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"properties",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"value",void 0),ge=(0,r._)([(0,p.j)("esri.rest.support.ImageIdentifyResult")],ge);const be=ge;let Re=class extends I.wq{constructor(){super(...arguments),this.geometries=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],Re.prototype,"geometries",void 0),Re=(0,r._)([(0,p.j)("esri.rest.support.ImagePixelLocationResult")],Re);const ve=Re;let we=class extends I.wq{constructor(){super(...arguments),this.attributes=null,this.location=null,this.locationId=null,this.rasterId=null,this.resolution=null,this.pixelValue=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"attributes",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],we.prototype,"location",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"locationId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"rasterId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"resolution",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"pixelValue",void 0),we=(0,r._)([(0,p.j)("esri.rest.support.ImageSample")],we);const _e=we;let Ce=class extends I.wq{constructor(){super(...arguments),this.samples=null}};(0,r._)([(0,l.Cb)({type:[_e],json:{write:!0}})],Ce.prototype,"samples",void 0),Ce=(0,r._)([(0,p.j)("esri.rest.support.ImageSampleResult")],Ce);const Se=Ce;function xe(e){const t=e?.time;if(t&&(null!=t.start||null!=t.end)){const i=[];null!=t.start&&i.push(t.start),null==t.end||i.includes(t.end)||i.push(t.end),e.time=i.join(",")}}async function Ie(e,t,i){const r=(0,de.en)(e),n=t.geometry?[t.geometry]:[],o=await(0,ce.aX)(n),a=t.toJSON();xe(a);const l=o&&o[0];(0,s.pC)(l)&&(a.geometry=l.toJSON());const u=(0,de.cv)({...r.query,f:"json",...a});return(0,de.lA)(u,i)}async function Fe(e,t,i){const r=(0,de.en)(e),n=t.geometry?[t.geometry]:[];return(0,ce.aX)(n).then((e=>{const n=t.toJSON(),o=e&&e[0];(0,s.pC)(o)&&(n.geometry=JSON.stringify(o.toJSON()));const a=(0,de.cv)({...r.query,f:"json",...n}),l=(0,de.lA)(a,i);return(0,f.default)(r.path+"/identify",l)})).then((e=>be.fromJSON(e.data)))}function Te(e){const{imageCoordinateSystem:t}=e;if(t){const{id:e,referenceServiceName:i}=t;return null!=e?i?{icsid:e,icsns:i}:{icsid:e}:{ics:t}}return e.toJSON()}function Ne(e,t){const i=Te(e),{icsid:r,icsns:n,wkid:s}=i;return null!=r?null==n||t?.toLowerCase().includes("/"+n.toLowerCase()+"/")?`0:${r}`:JSON.stringify(i):s?s.toString():JSON.stringify(i)}i(80442),i(10158);var De,je=i(4967),Pe=(i(67900),i(8744),i(98732),i(6570)),Oe=(i(9361),i(65091)),Me=i(38913),Ve=(i(58901),i(45091),i(57444)),Ae=(i(40330),i(98326),i(56545),i(41818)),Je=i(5396),Ze=(i(75935),i(28141),i(26059)),Ee=i(36679);let qe=De=class extends I.wq{constructor(){super(...arguments),this.angleNames=null,this.point=null,this.spatialReference=null,this.rasterId=null}clone(){return new De((0,R.d9)({angleNames:this.angleNames,point:this.point,spatialReference:this.spatialReference,rasterId:this.rasterId}))}};(0,r._)([(0,l.Cb)({type:[String],json:{name:"angleName",write:!0}})],qe.prototype,"angleNames",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],qe.prototype,"point",void 0),(0,r._)([(0,l.Cb)({type:me.Z,json:{write:!0}})],qe.prototype,"spatialReference",void 0),(0,r._)([(0,l.Cb)({type:u.z8,json:{write:!0}})],qe.prototype,"rasterId",void 0),qe=De=(0,r._)([(0,p.j)("esri.rest.support.ImageAngleParameters")],qe);const ze=qe;var Le,He=i(92835),ke=i(33955);let Be=Le=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.mosaicRule=null,this.renderingRule=null,this.pixelSize=null,this.raster=void 0,this.timeExtent=null}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=e.toJSON())}clone(){return new Le((0,R.d9)({geometry:this.geometry,mosaicRule:this.mosaicRule,renderingRule:this.renderingRule,pixelSize:this.pixelSize,raster:this.raster,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({types:m.qM,json:{read:ke.im}})],Be.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],Be.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],Be.prototype,"mosaicRule",void 0),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],Be.prototype,"renderingRule",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],Be.prototype,"pixelSize",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Be.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{read:{source:"time"},write:{target:"time"}}})],Be.prototype,"timeExtent",void 0),Be=Le=(0,r._)([(0,p.j)("esri.rest.support.ImageHistogramParameters")],Be);const Ge=Be;var Qe;let Ue=Qe=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.renderingRules=null,this.pixelSize=null,this.returnGeometry=!0,this.returnCatalogItems=!0,this.returnPixelValues=!0,this.maxItemCount=null,this.timeExtent=null,this.raster=void 0,this.viewId=void 0,this.processAsMultidimensional=!1}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=JSON.stringify(e.toJSON()))}set mosaicRule(e){let t=e;t&&t.mosaicMethod&&(t=K.fromJSON({...t.toJSON(),mosaicMethod:t.mosaicMethod,mosaicOperation:t.mosaicOperation})),this._set("mosaicRule",t)}writeMosaicRule(e,t,i){null!=e&&(t[i]=JSON.stringify(e.toJSON()))}set renderingRule(e){let t=e;t&&t.rasterFunction&&(t=F.Z.fromJSON({...t.toJSON(),rasterFunction:t.rasterFunction,rasterFunctionArguments:t.rasterFunctionArguments})),this._set("renderingRule",t)}writeRenderingRule(e,t,i){null!=e&&(t[i]=JSON.stringify(e.toJSON())),e.rasterFunctionDefinition&&(t[i]=JSON.stringify(e.rasterFunctionDefinition))}writeRenderingRules(e,t,i){null!=e&&(t[i]=JSON.stringify(e.map((e=>e.rasterFunctionDefinition||e.toJSON()))))}writePixelSize(e,t,i){null!=e&&(t[i]=JSON.stringify(e))}writeTimeExtent(e,t,i){if(null!=e){const r=(0,s.pC)(e.start)?e.start.getTime():null,n=(0,s.pC)(e.end)?e.end.getTime():null;t[i]=null!=r?null!=n?`${r},${n}`:`${r}`:null}}clone(){return new Qe((0,R.d9)({geometry:this.geometry,mosaicRule:this.mosaicRule,renderingRule:this.renderingRule,pixelSize:this.pixelSize,returnGeometry:this.returnGeometry,returnCatalogItems:this.returnCatalogItems,returnPixelValues:this.returnPixelValues,maxItemCount:this.maxItemCount,processAsMultidimensional:this.processAsMultidimensional,raster:this.raster,viewId:this.viewId,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],Ue.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],Ue.prototype,"mosaicRule",null),(0,r._)([(0,c.c)("mosaicRule")],Ue.prototype,"writeMosaicRule",null),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],Ue.prototype,"renderingRule",null),(0,r._)([(0,c.c)("renderingRule")],Ue.prototype,"writeRenderingRule",null),(0,r._)([(0,l.Cb)({type:[F.Z],json:{write:!0}})],Ue.prototype,"renderingRules",void 0),(0,r._)([(0,c.c)("renderingRules")],Ue.prototype,"writeRenderingRules",null),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],Ue.prototype,"pixelSize",void 0),(0,r._)([(0,c.c)("pixelSize")],Ue.prototype,"writePixelSize",null),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnGeometry",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnCatalogItems",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnPixelValues",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],Ue.prototype,"maxItemCount",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{write:{target:"time"}}})],Ue.prototype,"timeExtent",void 0),(0,r._)([(0,c.c)("timeExtent")],Ue.prototype,"writeTimeExtent",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"viewId",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"processAsMultidimensional",void 0),Ue=Qe=(0,r._)([(0,p.j)("esri.rest.support.ImageIdentifyParameters")],Ue);const We=Ue;var $e;let Ke=$e=class extends I.wq{constructor(){super(...arguments),this.geometries=null,this.rasterId=null}writeGeometry(e,t,i){t.geometries={geometryType:"esriGeometryPoint",geometries:e.map((e=>e.toJSON()))}}clone(){return new $e({geometries:this.geometries?.map((e=>e.clone()))??[],rasterId:this.rasterId})}};(0,r._)([(0,l.Cb)({type:[Q.Z],json:{write:!0}})],Ke.prototype,"geometries",void 0),(0,r._)([(0,c.c)("geometries")],Ke.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:u.z8,json:{write:!0}})],Ke.prototype,"rasterId",void 0),Ke=$e=(0,r._)([(0,p.j)("esri.rest.support.ImagePixelLocationParameters")],Ke);const Xe=Ke;var Ye;let et=Ye=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.interpolation="nearest",this.mosaicRule=null,this.outFields=null,this.pixelSize=null,this.returnFirstValueOnly=!0,this.sampleDistance=null,this.sampleCount=null,this.sliceId=null,this.timeExtent=null}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=e.toJSON())}set locations(e){if(e?.length){const t=new Oe.Z({spatialReference:e[0].spatialReference});t.points=e.map((e=>[e.x,e.y])),this._set("locations",e),this.geometry=t}}clone(){return new Ye((0,R.d9)({geometry:this.geometry,locations:this.locations,interpolation:this.interpolation,mosaicRule:this.mosaicRule,outFields:this.outFields,raster:this.raster,returnFirstValueOnly:this.returnFirstValueOnly,sampleDistance:this.sampleDistance,sampleCount:this.sampleCount,sliceId:this.sliceId,pixelSize:this.pixelSize,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({types:m.qM,json:{read:ke.im}})],et.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],et.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)()],et.prototype,"locations",null),(0,r._)([(0,l.Cb)({type:String,json:{type:X.c.jsonValues,read:X.c.read,write:X.c.write}})],et.prototype,"interpolation",void 0),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],et.prototype,"mosaicRule",void 0),(0,r._)([(0,l.Cb)({type:[String],json:{write:!0}})],et.prototype,"outFields",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],et.prototype,"pixelSize",void 0),(0,r._)([(0,l.Cb)({type:String,json:{write:!0}})],et.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],et.prototype,"returnFirstValueOnly",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sampleDistance",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sampleCount",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sliceId",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{read:{source:"time"},write:{target:"time"}}})],et.prototype,"timeExtent",void 0),et=Ye=(0,r._)([(0,p.j)("esri.rest.support.ImageSampleParameters")],et);const tt=et;var it=i(23808);const rt=(0,b.w)()({U1:"u1",U2:"u2",U4:"u4",U8:"u8",S8:"s8",U16:"u16",S16:"s16",U32:"u32",S32:"s32",F32:"f32",F64:"f64",C64:"c64",C128:"c128",UNKNOWN:"unknown"}),nt=new Set(["png","png8","png24","png32","jpg","bmp","gif","jpgpng","lerc","tiff"]),st=(0,l.Eg)(u.q9,{min:0,max:255}),ot=e=>{let t=class extends e{constructor(){super(...arguments),this._functionRasterInfos={},this._rasterJobHandler={instance:null,refCount:0,connectionPromise:null},this._cachedRendererJson=null,this._serviceSupportsMosaicRule=null,this._rasterAttributeTableFieldPrefix="Raster.",this.adjustAspectRatio=null,this.bandIds=void 0,this.capabilities=null,this.compressionQuality=void 0,this.compressionTolerance=.01,this.copyright=null,this.defaultMosaicRule=null,this.definitionExpression=null,this.exportImageServiceParameters=null,this.rasterInfo=null,this.fields=null,this.fullExtent=null,this.hasMultidimensions=!1,this.imageMaxHeight=4100,this.imageMaxWidth=4100,this.interpolation=void 0,this.minScale=0,this.maxScale=0,this.multidimensionalSubset=null,this.noData=null,this.noDataInterpretation=void 0,this.objectIdField=null,this.geometryType="polygon",this.typeIdField=null,this.types=[],this.pixelFilter=null,this.raster=void 0,this.sourceType=null,this.viewId=void 0,this.symbolizer=null,this.rasterFunctionInfos=null,this.serviceDataType=null,this.spatialReference=null,this.pixelType=null,this.serviceRasterInfo=null,this.sourceJSON=null,this.url=null,this.version=void 0}initialize(){this._set("exportImageServiceParameters",new Y({layer:this}))}readServiceSupportsMosaicRule(e,t){return this._isMosaicRuleSupported(t)}get _rasterFunctionNamesIndex(){const e=new Map;return!this.rasterFunctionInfos||(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.length<1||(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.forEach((t=>{e.set(t.name.toLowerCase().replace(/ /gi,"_"),t.name)})),e}readBandIds(e,t){if(Array.isArray(e)&&e.length>0&&e.every((e=>"number"==typeof e)))return e}readCapabilities(e,t){return this._readCapabilities(t)}writeCompressionQuality(e,t,i){null!=e&&"lerc"!==this.format&&(t[i]=e)}writeCompressionTolerance(e,t,i){"lerc"===this.format&&null!=e&&(t[i]=e)}readDefaultMosaicRule(e,t){return this._serviceSupportsMosaicRule?K.fromJSON(t):null}get fieldsIndex(){return this.fields?new te.Z(this.fields):null}set format(e){e&&nt.has(e.toLowerCase())&&this._set("format",e.toLowerCase())}readFormat(e,t){return"esriImageServiceDataTypeVector-UV"===t.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===t.serviceDataType||null!=this.pixelFilter?"lerc":"jpgpng"}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}set mosaicRule(e){let t=e;t&&t.mosaicMethod&&(t=K.fromJSON({...t.toJSON(),mosaicMethod:t.mosaicMethod,mosaicOperation:t.mosaicOperation})),this._set("mosaicRule",t)}readMosaicRule(e,t){const i=e||t.mosaicRule;return i?K.fromJSON(i):this._isMosaicRuleSupported(t)?K.fromJSON(t):null}writeMosaicRule(e,t,i){let r=this.mosaicRule;const n=this.definitionExpression;r?n&&n!==r.where&&(r=r.clone(),r.where=n):n&&(r=new K({where:n})),this._isValidCustomizedMosaicRule(r)&&(t[i]=r.toJSON())}get multidimensionalInfo(){return(0,s.pC)(this.serviceRasterInfo)?this.serviceRasterInfo.multidimensionalInfo:null}writeNoData(e,t,i){null!=e&&"number"==typeof e&&(t[i]=st(e))}readObjectIdField(e,t){if(!e){const i=t.fields.filter((e=>"esriFieldTypeOID"===e.type||"oid"===e.type));e=i&&i[0]&&i[0].name}return e}get parsedUrl(){return(0,_.mN)(this.url)}readSourceType(e,t){return this._isMosaicDataset(t)?"mosaic-dataset":"raster-dataset"}set renderer(e){this.loaded&&(e=this._configRenderer(e)),this._set("renderer",e)}readRenderer(e,t,i){const r=t?.layerDefinition?.drawingInfo?.renderer,n=(0,y.ij)(r,i);return null==n?null:("vector-field"===n.type&&t.symbolTileSize&&!r.symbolTileSize&&(n.symbolTileSize=t.symbolTileSize),V(n)||v.Z.getLogger(this.declaredClass).warn("ArcGISImageService","Imagery layer doesn't support given renderer type."),n)}writeRenderer(e,t,i){t.layerDefinition=t.layerDefinition||{},t.layerDefinition.drawingInfo=t.layerDefinition.drawingInfo||{},t.layerDefinition.drawingInfo.renderer=e.toJSON(),"vector-field"===e.type&&(t.symbolTileSize=e.symbolTileSize)}get rasterFields(){const e=this._rasterAttributeTableFieldPrefix||"Raster.",t=new ee.Z({name:"Raster.ItemPixelValue",alias:"Item Pixel Value",domain:null,editable:!1,length:50,type:"string"}),i=new ee.Z({name:"Raster.ServicePixelValue",alias:"Service Pixel Value",domain:null,editable:!1,length:50,type:"string"}),r=new ee.Z({name:"Raster.ServicePixelValue.Raw",alias:"Raw Service Pixel Value",domain:null,editable:!1,length:50,type:"string"});let n=this.fields?(0,R.d9)(this.fields):[];n.push(i),this.capabilities?.operations.supportsQuery&&this.fields&&this.fields.length>0&&n.push(t),this.version>=10.4&&(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.some((e=>"none"===e.name.toLowerCase()))&&n.push(r),(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.filter((e=>"none"!==e.name.toLowerCase())).forEach((e=>{n.push(new ee.Z({name:"Raster.ServicePixelValue."+e.name,alias:e.name,domain:null,editable:!1,length:50,type:"string"}))})),this._isVectorDataSet()&&(n.push(new ee.Z({name:"Raster.Magnitude",alias:"Magnitude",domain:null,editable:!1,type:"double"})),n.push(new ee.Z({name:"Raster.Direction",alias:"Direction",domain:null,editable:!1,type:"double"})));const{attributeTable:o}=this.rasterInfo??{};if((0,s.pC)(o)){const t=o.fields.filter((e=>"esriFieldTypeOID"!==e.type&&"value"!==e.name.toLowerCase())).map((t=>{const i=(0,R.d9)(t);return i.name=e+t.name,i}));n=n.concat(t)}return n}set renderingRule(e){let t=e;t&&t.rasterFunction&&(t=F.Z.fromJSON({...t.toJSON(),rasterFunction:t.rasterFunction,rasterFunctionArguments:t.rasterFunctionArguments})),this._set("renderingRule",t)}readRenderingRule(e,t){const i=t.rasterFunctionInfos;return t.renderingRule||i&&i.length&&"None"!==i[0].name?this._isRFTJson(t.renderingRule)?F.Z.fromJSON({rasterFunctionDefinition:t.renderingRule}):F.Z.fromJSON(t.renderingRule||{rasterFunctionInfos:t.rasterFunctionInfos}):null}writeRenderingRule(e,t,i){const r=e.toJSON();r.rasterFunctionDefinition?t[i]=r.rasterFunctionDefinition:t[i]=r}readSpatialReference(e,t){const i=e||t.extent.spatialReference;return i?me.Z.fromJSON(i):null}readPixelType(e){return rt.fromJSON(e)||e}writePixelType(e,t,i){((0,s.Wi)(this.serviceRasterInfo)||this.pixelType!==this.serviceRasterInfo.pixelType)&&(t[i]=rt.toJSON(e))}readVersion(e,t){let i=t.currentVersion;return i||(i=t.hasOwnProperty("fields")||t.hasOwnProperty("timeInfo")?10:9.3),i}applyFilter(e){let t=e;return this.pixelFilter&&(t=this._clonePixelData(e),this.pixelFilter(t)),t}async applyRenderer(e,t){let i=e;const{renderer:r,symbolizer:n,pixelFilter:s,bandIds:o}=this;if(!this._isPicture()&&r&&n&&!s){const s=JSON.stringify(this._cachedRendererJson)!==JSON.stringify(r.toJSON()),a=this._rasterJobHandler.instance;if(a){s&&(n.bind(),await a.updateSymbolizer(n,t),this._cachedRendererJson=r.toJSON());const l=await a.symbolize({bandIds:o,...e},t);i={extent:e.extent,pixelBlock:l}}else i={extent:e.extent,pixelBlock:n.symbolize({bandIds:o,...e})}}return i}destroy(){this._shutdownJobHandler()}increaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount++}decreaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount--,this._rasterJobHandler.refCount<=0&&this._shutdownJobHandler()}async computeAngles(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeAngles)throw new g.Z("imagery-layer:compute-angles","this operation is not supported on the input image service");return e=(0,u.TJ)(ze,e).clone(),async function(e,t,i){const r=t.toJSON();(0,s.pC)(r.angleName)&&(r.angleName=r.angleName.join(",")),(0,s.pC)(t.point)&&t.point.spatialReference?.imageCoordinateSystem&&(r.point.spatialReference=Te(t.point.spatialReference)),(0,s.pC)(t.spatialReference)&&t.spatialReference.imageCoordinateSystem&&(r.spatialReference=Ne(t.spatialReference));const n=(0,de.en)(e),o=(0,de.cv)({...n.query,f:"json",...r}),a=(0,de.lA)(o,i),{data:l}=await(0,f.default)(`${n.path}/computeAngles`,a);return l.spatialReference=l.spatialReference?null!=l.spatialReference.geodataXform?new me.Z({wkid:0,imageCoordinateSystem:l.spatialReference}):me.Z.fromJSON(l.spatialReference):null,"NaN"===l.north&&(l.north=null),"NaN"===l.up&&(l.up=null),new ye(l)}(this.url,e,this._getRequestOptions(t))}async computePixelSpaceLocations(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputePixelLocation)throw new g.Z("imagery-layer:compute-pixel-space-locations","this operation is not supported on the input image service");return e=(0,u.TJ)(Xe,e).clone(),async function(e,t,i){const r=t.toJSON(),{geometries:n}=t;if(n)for(let e=0;e<n.length;e++)n[e].spatialReference?.imageCoordinateSystem&&(r.geometries.geometries[e].spatialReference=Te(n[e].spatialReference));const s=(0,de.en)(e),o=(0,de.cv)({...s.query,f:"json",...r}),a=(0,de.lA)(o,i),{data:l}=await(0,f.default)(`${s.path}/computePixelLocation`,a);return ve.fromJSON(l)}(this.url,e,this._getRequestOptions(t))}async computeHistograms(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeHistograms)throw new g.Z("imagery-layer:compute-histograms","this operation is not supported on the input image service");e=(0,u.TJ)(Ge,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;return n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule&&(e.mosaicRule=r),i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=await Ie(e,t,i),n=(0,de.en)(e),{data:s}=await(0,f.default)(`${n.path}/computeHistograms`,r);return{histograms:s.histograms}}(this.url,e,this._getRequestOptions(t))}async computeStatisticsHistograms(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeStatisticsHistograms)throw new g.Z("imagery-layer:compute-statistics-histograms","this operation is not supported on the input image service");e=(0,u.TJ)(Ge,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;return n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule&&(e.mosaicRule=r),i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=await Ie(e,t,i),n=(0,de.en)(e),{data:s}=await(0,f.default)(`${n.path}/computeStatisticsHistograms`,r),{statistics:o}=s;return o?.length&&o.forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:o,histograms:s.histograms}}(this.url,e,this._getRequestOptions(t))}getField(e){const{fieldsIndex:t}=this;return(0,s.pC)(t)?t.get(e):void 0}getFieldDomain(e,t){const i=this.getField(e);return i?i.domain:null}async fetchImage(e,t,i,r={}){if(null==e||null==t||null==i)throw new g.Z("imagery-layer:fetch-image","Insufficient parameters for requesting an image. A valid extent, width and height values are required.");if(this.renderer||this.symbolizer){const e=await this.generateRasterInfo(this.renderingRule,{signal:r.signal});e&&(this.rasterInfo=e)}const n=this.getExportImageServiceParameters(e,t,i,r.timeExtent);if(null==n){if(r.requestAsImageElement&&this._canRequestImageElement(this.format)){const e=document.createElement("canvas");return e.width=t,e.height=i,{imageOrCanvasElement:e}}const n=(this.bandIds?.length||this.rasterInfo?.bandCount)??0,s=t*i,o=this.rasterInfo?.pixelType??"unknown",a=[];for(let e=0;e<n;e++)a.push(re.Z.createEmptyBand(o,s));return{pixelData:{pixelBlock:new re.Z({width:t,height:i,pixels:a,mask:new Uint8Array(s),pixelType:o}),extent:e}}}const s={imageServiceParameters:n,imageProps:{extent:e,width:t,height:i,format:this.format},requestAsImageElement:r.requestAsImageElement&&!this.pixelFilter||!1,signal:r.signal};return this._requestArrayBuffer(s)}fetchKeyProperties(e){return(0,f.default)(i(this.parsedUrl)+"/keyProperties",{query:this._getQueryParams({renderingRule:this.version>=10.3?e?.renderingRule:null})}).then((e=>e.data))}fetchRasterAttributeTable(e){return this.version<10.1?Promise.reject(new g.Z("#fetchRasterAttributeTable()","Failed to get rasterAttributeTable")):(0,f.default)(i(this.parsedUrl)+"/rasterAttributeTable",{query:this._getQueryParams({renderingRule:this.version>=10.3?e?.renderingRule:null})}).then((e=>fe.default.fromJSON(e.data)))}getCatalogItemRasterInfo(e,t){const r={...t,query:this._getQueryParams()};return async function(e,t,i){const r=(0,de.en)(e),n=(0,de.cv)({...r?.query,f:"json"}),s=(0,de.lA)(n,i),o=`${r?.path}/${t}/info`,a=(0,f.default)(`${o}`,s),l=(0,f.default)(`${o}/keyProperties`,s),u=await Promise.allSettled([a,l]),p="fulfilled"===u[0].status?u[0].value.data:null,c="fulfilled"===u[1].status?u[1].value.data:null;let d=null;p.statistics?.length&&(d=p.statistics.map((e=>({min:e[0],max:e[1],avg:e[2],stddev:e[3]}))));const m=Pe.Z.fromJSON(p.extent),h=Math.ceil(m.width/p.pixelSizeX-.1),y=Math.ceil(m.height/p.pixelSizeY-.1),g=m.spatialReference,b=new Q.Z({x:p.pixelSizeX,y:p.pixelSizeY,spatialReference:g}),R=p.histograms?.length?p.histograms:null,v=new Ee.Z({origin:p.origin,blockWidth:p.blockWidth,blockHeight:p.blockHeight,firstPyramidLevel:p.firstPyramidLevel,maximumPyramidLevel:p.maxPyramidLevel});return new ne.Z({width:h,height:y,bandCount:p.bandCount,extent:m,spatialReference:g,pixelSize:b,pixelType:p.pixelType.toLowerCase(),statistics:d,histograms:R,keyProperties:c,storageInfo:v})}(i(this.parsedUrl),e,r)}async getCatalogItemICSInfo(e,t){const{data:r}=await(0,f.default)(i(this.parsedUrl)+"/"+e+"/info/ics",{query:this._getQueryParams(),...t}),n=r&&r.ics;if(!n)return;let s=null;try{s=(await(0,f.default)(i(this.parsedUrl)+"/"+e+"/info",{query:this._getQueryParams(),...t})).data.extent}catch{}if(!s||!s.spatialReference)return{ics:n,icsToPixelTransform:null,icsExtent:null,northDirection:null};const o=this.version>=10.7?(0,f.default)(i(this.parsedUrl)+"/"+e+"/info/icstopixel",{query:this._getQueryParams(),...t}).then((e=>e.data)).catch((()=>({}))):{},a=s.spatialReference,l={geometries:JSON.stringify({geometryType:"esriGeometryEnvelope",geometries:[s]}),inSR:a.wkid||JSON.stringify(a),outSR:"0:"+e},u=(0,f.default)(i(this.parsedUrl)+"/project",{query:this._getQueryParams(l),...t}).then((e=>e.data)).catch((()=>({}))),p=(s.xmin+s.xmax)/2,c=(s.ymax-s.ymin)/6,d=s.ymin+c,m=[];for(let e=0;e<5;e++)m.push({x:p,y:d+c*e});const h={geometries:JSON.stringify({geometryType:"esriGeometryPoint",geometries:m}),inSR:a.wkid||JSON.stringify(a),outSR:"0:"+e},y=(0,f.default)(i(this.parsedUrl)+"/project",{query:this._getQueryParams(h),...t}).then((e=>e.data)).catch((()=>({}))),g=await Promise.all([o,u,y]);let b=g[0].ipxf;if(null==b){const e=n.geodataXform?.xf_0;"topup"===e?.name?.toLowerCase()&&6===e?.coefficients?.length&&(b={affine:{name:"ics [sensor: Frame] to pixel (column, row) transformation",coefficients:e.coefficients,cellsizeRatio:0,type:"GeometricXform"}})}const R=Pe.Z.fromJSON(g[1]&&g[1].geometries&&g[1].geometries[0]);R&&(R.spatialReference=new me.Z({wkid:0,imageCoordinateSystem:n}));const v=g[2].geometries?g[2].geometries.filter((e=>null!=e&&null!=e.x&&null!=e.y&&"NaN"!==e.x&&"NaN"!==e.y)):[],w=v.length;if(w<3)return{ics:n,icsToPixelTransform:b,icsExtent:R,northDirection:null};let _=0,C=0,S=0,x=0;for(let e=0;e<w;e++)_+=v[e].x,C+=v[e].y,S+=v[e].x*v[e].x,x+=v[e].x*v[e].y;const I=(w*x-_*C)/(w*S-_*_);let F=0;const T=v[4].x>v[0].x,N=v[4].y>v[0].y;return I===1/0?F=N?90:270:0===I?F=T?0:180:I>0?F=T?180*Math.atan(I)/Math.PI:180*Math.atan(I)/Math.PI+180:I<0&&(F=N?180+180*Math.atan(I)/Math.PI:360+180*Math.atan(I)/Math.PI),{ics:n,icsToPixelTransform:b,icsExtent:R,northDirection:F}}async generateRasterInfo(e,t){if(this.serviceRasterInfo&&(!e||"none"===e.functionName?.toLowerCase()||this._isVectorFieldResampleFunction(e)))return this.serviceRasterInfo;const i=function(e){if(!e)return null;const t=JSON.stringify(e).match(/"rasterFunction":"(.*?")/gi)?.map((e=>e.replace('"rasterFunction":"',"").replace('"',"")));return t?t.join("/"):null}(e);if(!i)return null;if(this._functionRasterInfos[i])return this._functionRasterInfos[i];const r=this._generateRasterInfo(e,t);this._functionRasterInfos[i]=r;try{return await r}catch{return this._functionRasterInfos[i]=null,null}}getExportImageServiceParameters(e,t,r,n){const o=Ne((e=e.clone().shiftCentralMeridian()).spatialReference,i(this.parsedUrl));this.pixelType!==this.serviceRasterInfo?.pixelType&&(this.exportImageServiceParameters.pixelType=this.pixelType);const a=this.exportImageServiceParameters.toJSON(),{bandIds:l,noData:u}=a;let{renderingRule:p}=a;const c=this.renderingRule?.rasterFunctionDefinition,d=!this.renderer||"raster-stretch"===this.renderer.type;if(l?.length&&this._hasRenderingRule(this.renderingRule)&&!c&&d){const e={rasterFunction:"ExtractBand",rasterFunctionArguments:{BandIds:l}};if("Stretch"===p.rasterFunction)e.rasterFunctionArguments.Raster=p.rasterFunctionArguments.Raster,p.rasterFunctionArguments.Raster=e;else if("Colormap"===p.rasterFunction){const t=p.rasterFunctionArguments.Raster;"Stretch"===t?.rasterFunction?(e.rasterFunctionArguments.Raster=t.rasterFunctionArguments.Raster,t.rasterFunctionArguments.Raster=e):(e.rasterFunctionArguments.Raster=t,p.rasterFunctionArguments.Raster=e)}else e.rasterFunctionArguments.Raster=p,p=e;a.bandIds=void 0}else a.bandIds=l?.join(",");u instanceof Array&&u.length>0&&(a.noData=u.join(","));const m=this._serviceSupportsMosaicRule?this._combineMosaicRuleWithTimeExtent(this.exportImageServiceParameters.mosaicRule,n):null;a.mosaicRule=(0,s.pC)(m)?JSON.stringify(m):null;const{multidimensionalSubset:h}=this;if(h&&(0,s.pC)(m)&&m.multidimensionalDefinition&&(0,oe.nb)(m.multidimensionalDefinition,h))return null;a.renderingRule=this._getRenderingRuleString(F.Z.fromJSON(p));const y={};if(n){const{start:e,end:t}=n.toJSON();let i;if(e&&t&&e===t?(y.time=""+e,i=[e]):null==e&&null==t||(y.time=`${e??"null"},${t??"null"}`,i=null!=e&&null!=t?[e,t]:[e??t]),i&&h){const e=new x.Z({variableName:"",dimensionName:"StdTime",isSlice:!0,values:i});if((0,oe.nb)([e],h))return null}}return{bbox:e.xmin+","+e.ymin+","+e.xmax+","+e.ymax,bboxSR:o,imageSR:o,size:t+","+r,...a,...y}}async getSamples(e,t){if(!(await this._fetchCapabilities(t?.signal))?.operations.supportsGetSamples)throw new g.Z("imagery-layer:get-samples","getSamples operation is not supported on the input image service");e=(0,u.TJ)(tt,e).clone();const{raster:i}=this;return i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=t.toJSON();xe(r),r.outFields?.length&&(r.outFields=r.outFields.join(","));const n=(await(0,ce.aX)(t.geometry))?.[0];(0,s.pC)(n)&&(r.geometry=n.toJSON());const o=(0,de.en)(e),a=(0,de.cv)({...o.query,f:"json",...r}),l=(0,de.lA)(a,i),{data:u}=await(0,f.default)(`${o.path}/getSamples`,l),p=u?.samples?.map((e=>{const t="NaN"===e.value||""===e.value?null:e.value.split(" ").map((e=>Number(e)));return{...e,pixelValue:t}}));return Se.fromJSON({samples:p})}(this.url,e,this._getRequestOptions(t))}async identify(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsIdentify)throw new g.Z("imagery-layer:query-rasters","query operation is not supported on the input image service");e=(0,u.TJ)(We,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;if(n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule){const t=this._combineMosaicRuleWithTimeExtent(r,e.timeExtent);e.mosaicRule=(0,s.Wg)(t)}return i&&null==e.raster&&(e.raster=i),Fe(this.url,e,this._getRequestOptions(t))}createQuery(){const e=new Ve.Z;return e.outFields=["*"],e.returnGeometry=!0,e.where=this.definitionExpression||"1=1",e}async queryRasters(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,je.e)(this.url,e,t)}async queryObjectIds(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,Je.G)(this.url,e,t)}async queryRasterCount(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,Ae.P)(this.url,e,t)}async queryVisibleRasters(e,t){if(!e)throw new g.Z("imagery-layer: query-visible-rasters","missing query parameter");await this.load();const{pixelSize:i,returnDomainValues:r,returnTopmostRaster:n,showNoDataRecords:o}=t||{pixelSize:null,returnDomainValues:!1,returnTopmostRaster:!1,showNoDataRecords:!1};let a=!1,l=null,u=null;const p="raster.servicepixelvalue",c=this._rasterFunctionNamesIndex;if((0,s.pC)(e.outFields)&&(a=e.outFields.some((e=>!e.toLowerCase().includes(p))),this.version>=10.4)){const t=e.outFields.filter((e=>e.toLowerCase().includes(p)&&e.length>p.length)).map((e=>{const t=e.slice(p.length+1);return[this._updateRenderingRulesFunctionName(t,c),t]}));l=t.map((e=>new F.Z({functionName:e[0]}))),u=t.map((e=>e[1]));const{renderingRule:i}=this;0===l.length?i?.functionName?(l.push(i),u.push(i.functionName)):l=null:i?.functionName&&!l.some((e=>e.functionName===i.functionName))&&(l.push(i),u.push(i.functionName))}const d=(0,s.Wi)(e.outSpatialReference)||e.outSpatialReference.equals(this.spatialReference),m=e.timeExtent||this.timeExtent,h=this._combineMosaicRuleWithTimeExtent(this.exportImageServiceParameters.mosaicRule,m),y=this._getQueryParams({geometry:e.geometry,timeExtent:m,mosaicRule:h,renderingRule:this.version<10.4?this.renderingRule:null,renderingRules:l,pixelSize:i,returnCatalogItems:a,returnGeometry:d,raster:this.raster,maxItemCount:n?1:null});delete y.f;const f=new We(y);try{await this.generateRasterInfo(this.renderingRule);const i=await Fe(this.url,f,{signal:t?.signal,query:{...this.customParameters}}),n=e.outFields,l=null!=i.value&&i.value.toLowerCase().includes("nodata");if(!a||d||!i?.catalogItems?.features.length||!o&&l)return this._processVisibleRastersResponse(i,{returnDomainValues:r,templateRRFunctionNames:u,showNoDataRecords:o,templateFields:n});const p=this.objectIdField||"ObjectId",c=i.catalogItems?.features??[],m=c.map((e=>e.attributes?.[p])),h=new Ve.Z({objectIds:m,returnGeometry:!0,outSpatialReference:e.outSpatialReference,outFields:[p]}),y=await this.queryRasters(h);return y?.features?.length&&y.features.forEach((t=>{c.forEach((i=>{i.attributes[p]===t.attributes[p]&&(i.geometry=new Me.Z(t.geometry),(0,s.pC)(e.outSpatialReference)&&(i.geometry.spatialReference=e.outSpatialReference))}))})),this._processVisibleRastersResponse(i,{returnDomainValues:r,templateRRFunctionNames:u,showNoDataRecords:o,templateFields:n})}catch{throw new g.Z("imagery-layer:query-visible-rasters","encountered error when querying visible rasters")}}async fetchVariableStatisticsHistograms(e,t){const r=(0,f.default)(i(this.parsedUrl)+"/statistics",{query:this._getQueryParams({variable:e}),signal:t}).then((e=>e.data?.statistics)),n=(0,f.default)(i(this.parsedUrl)+"/histograms",{query:this._getQueryParams({variable:e}),signal:t}).then((e=>e.data?.histograms)),s=await Promise.all([r,n]);return s[0]&&s[0].forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:s[0]||null,histograms:s[1]||null}}async createFlowMesh(e,t){const i=this._rasterJobHandler.instance;return i?i.createFlowMesh(e,t):(0,it.GE)(e.meshType,e.simulationSettings,e.flowData,(0,s.pC)(t.signal)?t.signal:(new AbortController).signal)}getMultidimensionalSubsetVariables(e){const t=e??this.multidimensionalInfo;return(0,oe.jj)(this.multidimensionalSubset,t)}async _fetchService(e){await this._fetchServiceInfo(e),this.rasterInfo||(this.rasterInfo=this.serviceRasterInfo);const t=this.sourceJSON,r=(0,s.pC)(this.serviceRasterInfo)?Promise.resolve(this.serviceRasterInfo):(0,Ze.g)(i(this.parsedUrl),t,{signal:e,query:this._getQueryParams()}).then((e=>(this._set("serviceRasterInfo",e),e))),n=this._hasRenderingRule(this.renderingRule)?this.generateRasterInfo(this.renderingRule,{signal:e}):null,o=this._getRasterFunctionInfos();return Promise.all([r,n,o]).then((e=>{e[1]?this._set("rasterInfo",e[1]):this._set("rasterInfo",e[0]),e[2]&&this._set("rasterFunctionInfos",e[2]),this.renderer&&!this._isSupportedRenderer(this.renderer)&&(this._set("renderer",null),v.Z.getLogger(this.declaredClass).warn("ArcGISImageService","Switching to the default renderer. Renderer applied is not valid for this Imagery Layer")),this._set("renderer",this._configRenderer(this.renderer)),this.addHandles([(0,w.YP)((()=>this.renderingRule),(e=>{(this.renderer||this.symbolizer||this.popupEnabled&&this.popupTemplate)&&this.generateRasterInfo(e).then((e=>{e&&(this.rasterInfo=e)}))}))]);const{serviceRasterInfo:t}=this;t&&(0,s.pC)(t.multidimensionalInfo)&&this._updateMultidimensionalDefinition(t)}))}_combineMosaicRuleWithTimeExtent(e,t){const i=this.timeInfo;if((0,s.Wi)(e)||(0,s.Wi)(this.multidimensionalInfo)||(0,s.Wi)(t)||(0,s.Wi)(i?.startField))return e;const{startField:r}=i,n=this.multidimensionalInfo.variables.some((e=>e.dimensions.some((e=>e.name===r))))?r:"StdTime";if(e=e.clone(),"mosaic-dataset"===this.sourceType)return e.multidimensionalDefinition=e.multidimensionalDefinition?.filter((e=>e.dimensionName!==n)),this._cleanupMultidimensionalDefinition(e);e.multidimensionalDefinition=e.multidimensionalDefinition||[];const o=e.multidimensionalDefinition.filter((e=>e.dimensionName===n)),a=(0,s.pC)(t.start)?t.start.getTime():null,l=(0,s.pC)(t.end)?t.end.getTime():null,u=null==a||null==l||a===l,p=u?[a||l]:[[a,l]],c=this.version>=10.8;if(o.length)o.forEach((e=>{e.dimensionName===n&&(c?(e.dimensionName=null,e.isSlice=!1,e.values=[]):(e.isSlice=u,e.values=p))}));else if(!c){const t=e.multidimensionalDefinition.filter((e=>null!=e.variableName&&null==e.dimensionName));t.length?t.forEach((e=>{e.dimensionName=n,e.isSlice=u,e.values=p})):e.multidimensionalDefinition.push(new x.Z({variableName:"",dimensionName:n,isSlice:u,values:p}))}return this._cleanupMultidimensionalDefinition(e)}_cleanupMultidimensionalDefinition(e){return(0,s.Wi)(e)?null:(e.multidimensionalDefinition&&(e.multidimensionalDefinition=e.multidimensionalDefinition.filter((e=>!(!e.variableName&&!e.dimensionName))),0===e.multidimensionalDefinition.length&&(e.multidimensionalDefinition=null)),"mosaic-dataset"!==this.sourceType&&null==e.multidimensionalDefinition?null:e)}async _prepareForQuery(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsQuery)throw new g.Z("imagery-layer:query-rasters","query operation is not supported on the input image service");return e=(0,s.pC)(e)?(0,u.TJ)(Ve.Z,e):this.createQuery(),t=this._getRequestOptions(t),this.raster&&(t.query={...t.query,raster:this.raster}),{query:e,requestOptions:t}}async _initJobHandler(){if(null!=this._rasterJobHandler.connectionPromise)return this._rasterJobHandler.connectionPromise;const e=new se.Z;this._rasterJobHandler.connectionPromise=e.initialize().then((()=>{this._rasterJobHandler.instance=e}),(()=>{})),await this._rasterJobHandler.connectionPromise}_shutdownJobHandler(){this._rasterJobHandler.instance&&this._rasterJobHandler.instance.destroy(),this._rasterJobHandler.instance=null,this._rasterJobHandler.connectionPromise=null,this._rasterJobHandler.refCount=0,this._cachedRendererJson=null}_isSupportedRenderer(e){const{rasterInfo:t,renderingRule:i}=this;return"unique-value"===e.type&&this._hasRenderingRule(i)&&1===t?.bandCount&&["u8","s8"].includes(t.pixelType)||null!=t&&null!=e&&(0,ue.U0)(t).includes(e.type)}async _fetchCapabilities(e){return this.capabilities||await this._fetchServiceInfo(e),this.capabilities}async _fetchServiceInfo(e){let t=this.sourceJSON;if(!t){const{data:r,ssl:n}=await(0,f.default)(i(this.parsedUrl),{query:this._getQueryParams(),signal:e});t=r,this.sourceJSON=t,n&&(this.url=this.url.replace(/^http:/i,"https:"))}if(t.capabilities?.toLowerCase().split(",").map((e=>e.trim())).indexOf("tilesonly")>-1)throw new g.Z("imagery-layer:fetch-service-info","use ImageryTileLayer to open tiles-only image services");this.read(t,{origin:"service",url:this.parsedUrl})}_isMosaicDataset(e){return e.serviceSourceType?"esriImageServiceSourceTypeMosaicDataset"===e.serviceSourceType:e.fields?.length>0}_isMosaicRuleSupported(e){if(!e)return!1;const t=this._isMosaicDataset(e),i=e.currentVersion>=10.71&&e.hasMultidimensions&&!(e.fields?.length>1);return t||i}_isVectorFieldResampleFunction(e){if((0,s.Wi)(e))return!1;const{functionName:t,functionArguments:i}=e,r="resample"===t?.toLowerCase(),n=i?.ResampleType||i?.resampleType;return r&&(7===n||10===n)}_isPicture(){return!this.format||this.format.includes("jpg")||this.format.includes("png")}_configRenderer(e){if(!this._isPicture()&&!this.pixelFilter||this._isVectorDataSet()){if(!this.bandIds&&this.rasterInfo&&this.rasterInfo.bandCount>=3){const e=(0,ue.YD)(this.rasterInfo);!e||3===this.rasterInfo.bandCount&&0===e[0]&&1===e[1]&&2===e[2]||(this.bandIds=e)}e||(e=(0,ue.Ob)(this.rasterInfo,{bandIds:this.bandIds,variableName:this.renderingRule?null:this.mosaicRule?.multidimensionalDefinition?.[0].variableName}));const t=(0,ue.ol)(e.toJSON());this.symbolizer?(this.symbolizer.rendererJSON=t,this.symbolizer.rasterInfo=this.rasterInfo):this.symbolizer=new pe.Z({rendererJSON:t,rasterInfo:this.rasterInfo}),this.symbolizer.bind().success||(this.symbolizer=null)}return e}_clonePixelData(e){return null==e?e:{extent:e.extent&&e.extent.clone(),pixelBlock:(0,s.pC)(e.pixelBlock)?e.pixelBlock.clone():null}}_getQueryParams(e){e&&(0,s.pC)(e.renderingRule)&&"string"!=typeof e.renderingRule&&(e.renderingRule=this._getRenderingRuleString(e.renderingRule));const{raster:t,viewId:i}=this;return{raster:t,viewId:i,f:"json",...e,...this.customParameters}}_getRequestOptions(e){return{...e,query:{...e?.query,...this.customParameters}}}_decodePixelBlock(e,t,i){return this._rasterJobHandler.instance?this._rasterJobHandler.instance.decode({data:e,options:t}):(0,ae.J)(e,t,i)}async _getRasterFunctionInfos(e){const t=this.sourceJSON.rasterFunctionInfos;return this.loaded?t:t&&this.version>=10.3?1===t.length&&"none"===t[0].name.toLowerCase()?t:(await(0,f.default)(i(this.parsedUrl)+"/rasterFunctionInfos",{query:this._getQueryParams(),signal:e})).data?.rasterFunctionInfos:null}_canRequestImageElement(e){return!this.pixelFilter&&(!e||e.includes("png"))}async _requestArrayBuffer(e){const{imageProps:t,requestAsImageElement:r,signal:n}=e;if(r&&this._canRequestImageElement(t.format))return{imageOrCanvasElement:(await(0,f.default)(i(this.parsedUrl)+"/exportImage",{responseType:"image",query:this._getQueryParams({f:"image",...this.refreshParameters,...e.imageServiceParameters}),signal:n})).data,params:t};const s=this._initJobHandler(),o=(0,f.default)(i(this.parsedUrl)+"/exportImage",{responseType:"array-buffer",query:this._getQueryParams({f:"image",...e.imageServiceParameters}),signal:n}),a=(await Promise.all([o,s]))[0].data,l=t.format||"jpgpng";let u=l;if("bsq"!==u&&"bip"!==u&&(u=(0,ae.y)(a)),!u)throw new g.Z("imagery-layer:fetch-image","unsupported format signature "+String.fromCharCode.apply(null,new Uint8Array(a)));const p={signal:n},c="gif"===l||"bmp"===l||l.includes("png")&&("png"===u||"jpg"===u)?(0,ae.J)(a,{useCanvas:!0,...t},p):this._decodePixelBlock(a,{width:t.width,height:t.height,planes:null,pixelType:null,noDataValue:null,format:l},p);return{pixelData:{pixelBlock:await c,extent:t.extent},params:t}}_generateRasterInfo(e,t){const r={...t,query:this._getQueryParams()};return(0,Ze.N)(i(this.parsedUrl),e,r)}_isValidCustomizedMosaicRule(e){return e&&JSON.stringify(e.toJSON())!==JSON.stringify(this.defaultMosaicRule?.toJSON())}_updateMultidimensionalDefinition(e){if(this._isValidCustomizedMosaicRule(this.mosaicRule))return;const t=(0,oe.Tj)(e,{multidimensionalSubset:this.multidimensionalSubset});if((0,s.pC)(t)&&t.length>0){this.mosaicRule=this.mosaicRule||new K;const e=this.mosaicRule.multidimensionalDefinition;!this.sourceJSON.defaultVariableName&&this.renderingRule&&"none"!==this.renderingRule.functionName?.toLowerCase()&&t.forEach((e=>e.variableName="")),(!e||e&&e.length<=0)&&(this.mosaicRule.multidimensionalDefinition=t)}}_processVisibleRastersResponse(e,t){t=t||{};const i=e.value,{templateRRFunctionNames:r,showNoDataRecords:n,returnDomainValues:o,templateFields:a}=t,l=e.processedValues;let u=e.catalogItems&&e.catalogItems.features,p=e.properties&&e.properties.Values&&e.properties.Values.map((e=>e.replace(/ /gi,", ")))||[];const c=this.objectIdField||"ObjectId",d="string"==typeof i&&i.toLowerCase().includes("nodata"),m=[];if(i&&!u&&!d){const e={};e[c]=0,p=[i],u=[new h.Z(this.fullExtent,null,e)]}if(!u)return[];let y,f,g;this._updateResponseFieldNames(u,a),d&&!n&&(u=[]);for(let e=0;e<u.length;e++){if(y=u[e],null!=i){if(f=p[e],g=this.renderingRule&&l&&l.length>0&&r&&r.length>0&&r.includes(this.renderingRule.functionName)?l[r.indexOf(this.renderingRule.functionName)]:i,"nodata"===f.toLowerCase()&&!n)continue;const t="Raster.ItemPixelValue",o="Raster.ServicePixelValue";y.attributes[t]=f,y.attributes[o]=g,this._updateFeatureWithMagDirValues(y,f);const a=this.fields&&this.fields.length>0;let u=this.renderingRule&&(0,s.pC)(this.serviceRasterInfo?.attributeTable)?a?f:i:g;this.renderingRule||(u=a?f:i),this._updateFeatureWithRasterAttributeTableValues(y,u)}if(y.sourceLayer=y.layer=this,o&&this._updateFeatureWithDomainValues(y),r&&l&&r.length===l.length)for(let e=0;e<r.length;e++){const t="Raster.ServicePixelValue."+r[e];y.attributes[t]=l[e]}m.push(u[e])}return m}_updateFeatureWithRasterAttributeTableValues(e,t){const i=this.rasterInfo&&this.rasterInfo.attributeTable||this.serviceRasterInfo?.attributeTable;if((0,s.Wi)(i))return;const{features:r,fields:n}=i,o=n.map((e=>e.name)).filter((e=>"value"===e.toLowerCase())),a=o&&o[0];if(!a)return;const l=r.filter((e=>e.attributes[a]===(null!=t?parseInt(t,10):null)));l&&l[0]&&n.forEach((t=>{const i=this._rasterAttributeTableFieldPrefix+t.name;e.attributes[i]=l[0].attributes[t.name]}))}_updateFeatureWithMagDirValues(e,t){if(!this._isVectorDataSet())return;const i=t.split(/,\s*/).map((e=>parseFloat(e))),r=i.map((e=>[e])),n=i.map((e=>({minValue:e,maxValue:e,noDataValue:null}))),s=new re.Z({height:1,width:1,pixelType:"f32",pixels:r,statistics:n});null!=this.pixelFilter&&this.pixelFilter({pixelBlock:s,extent:new Pe.Z(0,0,0,0,this.spatialReference)});const o="esriImageServiceDataTypeVector-MagDir"===this.serviceDataType?[s.pixels[0][0],s.pixels[1][0]]:(0,le.Tg)([s.pixels[0][0],s.pixels[1][0]]);e.attributes["Raster.Magnitude"]=o[0],e.attributes["Raster.Direction"]=o[1]}_updateFeatureWithDomainValues(e){const t=this.fields&&this.fields.filter((e=>e.domain&&"coded-value"===e.domain.type));null!=t&&t.forEach((t=>{const i=e.attributes[t.name];if(null!=i){const r=t.domain.codedValues.find((e=>e.code===i));r&&(e.attributes[t.name]=r.name)}}))}_updateResponseFieldNames(e,t){if(!t||t.length<1)return;const i=this.fieldsIndex;(0,s.Wi)(i)||e.forEach((e=>{if(e&&e.attributes)for(const r of t){const t=i.get(r)?.name;t&&t!==r&&(e.attributes[r]=e.attributes[t],delete e.attributes[t])}}))}_getRenderingRuleString(e){if(this._hasRenderingRule(e)){let t=e.toJSON();return t=t.rasterFunctionDefinition??t,(t.thumbnail||t.thumbnailEx)&&(t.thumbnail=t.thumbnailEx=null),JSON.stringify(t)}return null}_hasRenderingRule(e){return null!=e&&null!=e.functionName&&"none"!==e.functionName.toLowerCase()}_updateRenderingRulesFunctionName(e,t){if(!e||e.length<1)return;if("Raw"===e)return e.replace("Raw","None");const i=e.toLowerCase().replace(/ /gi,"_");return t.has(i)?t.get(i):e}_isRFTJson(e){return e&&e.name&&e.arguments&&e.function&&e.hasOwnProperty("functionType")}_isVectorDataSet(){return"esriImageServiceDataTypeVector-UV"===this.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===this.serviceDataType}_readCapabilities(e){const t=e.capabilities?e.capabilities.toLowerCase().split(",").map((e=>e.trim())):["image","catalog"],{currentVersion:i,advancedQueryCapabilities:r,maxRecordCount:n}=e,s=t.includes("image"),o="esriImageServiceDataTypeElevation"===e.serviceDataType,a=!!(e.spatialReference||e.extent&&e.extent.spatialReference),l=t.includes("edit");return{data:{supportsAttachment:!1},operations:{supportsComputeHistograms:s,supportsExportImage:s,supportsIdentify:s,supportsMeasure:t.includes("mensuration")&&a,supportsDownload:t.includes("download"),supportsQuery:t.includes("catalog")&&e.fields&&e.fields.length>0,supportsGetSamples:i>=10.2&&s,supportsProject:i>=10.3&&s,supportsComputeStatisticsHistograms:i>=10.4&&s,supportsQueryBoundary:i>=10.6&&s,supportsCalculateVolume:i>=10.7&&o,supportsComputePixelLocation:i>=10.7&&t.includes("catalog"),supportsComputeAngles:i>=10.91,supportsAdd:l,supportsDelete:l,supportsEditing:l,supportsUpdate:l,supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsChangeTracking:!1,supportsQueryAttachments:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsExceedsLimitStatistics:!1,supportsQueryAnalytics:!1,supportsQueryTopFeatures:!1},query:{maxRecordCount:n,maxRecordCountFactor:void 0,supportsStatistics:!!r?.supportsStatistics,supportsOrderBy:!!r?.supportsOrderBy,supportsDistinct:!!r?.supportsDistinct,supportsPagination:!!r?.supportsPagination,supportsStandardizedQueriesOnly:!!r?.useStandardizedQueries,supportsPercentileStatistics:!!r?.supportsPercentileStatistics,supportsCentroid:!!r?.supportsReturningGeometryCentroid,supportsDistance:!!r?.supportsQueryWithDistance,supportsExtent:!!r?.supportsReturningQueryExtent,supportsGeometryProperties:!!r?.supportsReturningGeometryProperties,supportsHavingClause:!!r?.supportsHavingClause,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsMaxRecordCountFactor:!1,supportsSqlExpression:!1,supportsTopFeaturesQuery:!1,supportsQueryByOthers:!1,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!1,supportsCacheHint:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!!r?.supportsDefaultSR,supportsCompactGeometry:!1,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}}}};function i(e){return e?.path??""}return(0,r._)([(0,l.Cb)()],t.prototype,"_functionRasterInfos",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"_rasterJobHandler",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"_cachedRendererJson",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"_serviceSupportsMosaicRule",void 0),(0,r._)([(0,C.r)("_serviceSupportsMosaicRule",["currentVersion","fields"])],t.prototype,"readServiceSupportsMosaicRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"_rasterAttributeTableFieldPrefix",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"_rasterFunctionNamesIndex",null),(0,r._)([(0,l.Cb)()],t.prototype,"adjustAspectRatio",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{write:!0}})],t.prototype,"bandIds",void 0),(0,r._)([(0,C.r)("bandIds")],t.prototype,"readBandIds",null),(0,r._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],t.prototype,"capabilities",void 0),(0,r._)([(0,C.r)("service","capabilities",["capabilities","currentVersion","serviceDataType"])],t.prototype,"readCapabilities",null),(0,r._)([(0,l.Cb)({type:Number})],t.prototype,"compressionQuality",void 0),(0,r._)([(0,c.c)("compressionQuality")],t.prototype,"writeCompressionQuality",null),(0,r._)([(0,l.Cb)({type:Number})],t.prototype,"compressionTolerance",void 0),(0,r._)([(0,c.c)("compressionTolerance")],t.prototype,"writeCompressionTolerance",null),(0,r._)([(0,l.Cb)({json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,dependsOn:["_serviceSupportsMosaicRule"]})],t.prototype,"defaultMosaicRule",void 0),(0,r._)([(0,C.r)("defaultMosaicRule",["defaultMosaicMethod"])],t.prototype,"readDefaultMosaicRule",null),(0,r._)([(0,l.Cb)({type:String,json:{name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],t.prototype,"definitionExpression",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,constructOnly:!0})],t.prototype,"exportImageServiceParameters",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"rasterInfo",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:[ee.Z]})],t.prototype,"fields",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"fieldsIndex",null),(0,r._)([(0,l.Cb)({type:["png","png8","png24","png32","jpg","bmp","gif","jpgpng","lerc","tiff"],json:{write:!0}})],t.prototype,"format",null),(0,r._)([(0,C.r)("service","format",["serviceDataType"])],t.prototype,"readFormat",null),(0,r._)([(0,l.Cb)({type:Pe.Z})],t.prototype,"fullExtent",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"hasMultidimensions",void 0),(0,r._)([(0,l.Cb)({json:{read:{source:"maxImageHeight"}}})],t.prototype,"imageMaxHeight",void 0),(0,r._)([(0,l.Cb)({json:{read:{source:"maxImageWidth"}}})],t.prototype,"imageMaxWidth",void 0),(0,r._)([(0,l.Cb)({type:String,json:{type:X.c.jsonValues,read:X.c.read,write:X.c.write}})],t.prototype,"interpolation",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"minScale",void 0),(0,r._)([(0,C.r)("service","minScale")],t.prototype,"readMinScale",null),(0,r._)([(0,l.Cb)()],t.prototype,"maxScale",void 0),(0,r._)([(0,C.r)("service","maxScale")],t.prototype,"readMaxScale",null),(0,r._)([(0,l.Cb)({type:K})],t.prototype,"mosaicRule",null),(0,r._)([(0,C.r)("mosaicRule",["mosaicRule","defaultMosaicMethod"])],t.prototype,"readMosaicRule",null),(0,r._)([(0,c.c)("mosaicRule")],t.prototype,"writeMosaicRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"multidimensionalInfo",null),(0,r._)([(0,l.Cb)({type:ie.Z,json:{write:!0}})],t.prototype,"multidimensionalSubset",void 0),(0,r._)([(0,l.Cb)({json:{type:u.z8}})],t.prototype,"noData",void 0),(0,r._)([(0,c.c)("noData")],t.prototype,"writeNoData",null),(0,r._)([(0,l.Cb)({type:String,json:{type:X.k.jsonValues,read:X.k.read,write:X.k.write}})],t.prototype,"noDataInterpretation",void 0),(0,r._)([(0,l.Cb)({type:String,readOnly:!0,json:{read:{source:["fields"]}}})],t.prototype,"objectIdField",void 0),(0,r._)([(0,C.r)("objectIdField")],t.prototype,"readObjectIdField",null),(0,r._)([(0,l.Cb)({})],t.prototype,"geometryType",void 0),(0,r._)([(0,l.Cb)({})],t.prototype,"typeIdField",void 0),(0,r._)([(0,l.Cb)({})],t.prototype,"types",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"parsedUrl",null),(0,r._)([(0,l.Cb)({type:Function})],t.prototype,"pixelFilter",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"sourceType",void 0),(0,r._)([(0,C.r)("sourceType",["serviceSourceType","fields"])],t.prototype,"readSourceType",null),(0,r._)([(0,l.Cb)()],t.prototype,"viewId",void 0),(0,r._)([(0,l.Cb)({types:y.dr,json:{name:"layerDefinition.drawingInfo.renderer",origins:{"web-scene":{types:y.FK,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type&&"flow"!==e.type})}}}}})],t.prototype,"renderer",null),(0,r._)([(0,C.r)("renderer")],t.prototype,"readRenderer",null),(0,r._)([(0,c.c)("renderer")],t.prototype,"writeRenderer",null),(0,r._)([(0,l.Cb)()],t.prototype,"symbolizer",void 0),(0,r._)([(0,l.Cb)(S.Oh)],t.prototype,"opacity",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"rasterFields",null),(0,r._)([(0,l.Cb)({constructOnly:!0})],t.prototype,"rasterFunctionInfos",void 0),(0,r._)([(0,l.Cb)({type:F.Z})],t.prototype,"renderingRule",null),(0,r._)([(0,C.r)("renderingRule",["renderingRule","rasterFunctionInfos"])],t.prototype,"readRenderingRule",null),(0,r._)([(0,c.c)("renderingRule")],t.prototype,"writeRenderingRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"serviceDataType",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:me.Z})],t.prototype,"spatialReference",void 0),(0,r._)([(0,C.r)("spatialReference",["spatialReference","extent"])],t.prototype,"readSpatialReference",null),(0,r._)([(0,l.Cb)({json:{type:rt.jsonValues}})],t.prototype,"pixelType",void 0),(0,r._)([(0,C.r)("pixelType")],t.prototype,"readPixelType",null),(0,r._)([(0,c.c)("pixelType")],t.prototype,"writePixelType",null),(0,r._)([(0,l.Cb)({constructOnly:!0,type:ne.Z})],t.prototype,"serviceRasterInfo",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"sourceJSON",void 0),(0,r._)([(0,l.Cb)(S.HQ)],t.prototype,"url",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"version",void 0),(0,r._)([(0,C.r)("version",["currentVersion","fields","timeInfo"])],t.prototype,"readVersion",null),t=(0,r._)([(0,p.j)("esri.layers.mixins.ArcGISImageService")],t),t};var at=i(17287),lt=i(71612),ut=i(17017),pt=i(38009),ct=i(16859),dt=i(34760),mt=i(72965),ht=i(28294),yt=i(60199),ft=i(32163);let gt=class extends((0,lt.h)((0,ht.n)((0,mt.M)((0,pt.q)((0,ct.I)(ot((0,dt.Q)((0,ut.N)((0,at.Y)((0,o.R)(d.Z))))))))))){constructor(...e){super(...e),this.legendEnabled=!0,this.isReference=null,this.operationalLayerType="ArcGISImageServiceLayer",this.popupEnabled=!0,this.popupTemplate=null,this.type="imagery"}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=(0,s.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"]},e).catch(a.r9).then((()=>this._fetchService(t)))),Promise.resolve(this)}writeOperationalLayerType(e,t,i){const r="vector-field"===this.renderer?.type;t[i]=r?"ArcGISImageServiceVectorLayer":"ArcGISImageServiceLayer"}get defaultPopupTemplate(){return this.createPopupTemplate()}createPopupTemplate(e){const t=this.rasterFields,i=this.title,r=new Set;let n=!1,s=!1;this.capabilities&&(n=this.capabilities.operations.supportsQuery&&this.fields&&this.fields.length>0,s="esriImageServiceDataTypeVector-UV"===this.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===this.serviceDataType);const o=new Set;n&&o.add("raster.itempixelvalue");for(const e of t){const t=e.name.toLowerCase();o.has(t)||t.includes("raster.servicepixelvalue.")||r.add(e.name)}return s&&r.add("raster.magnitude").add("raster.direction"),(0,ft.eZ)({fields:t,title:i},{...e,visibleFieldNames:r})}queryFeatures(e,t){return this.queryRasters(e,t).then((e=>{if(e?.features)for(const t of e.features)t.layer=t.sourceLayer=this;return e}))}queryFeatureCount(e,t){return this.queryRasterCount(e,t)}redraw(){this.emit("redraw")}serviceSupportsSpatialReference(e){return(0,yt.D)(this,e)}};(0,r._)([(0,l.Cb)(S.rn)],gt.prototype,"legendEnabled",void 0),(0,r._)([(0,l.Cb)({type:["show","hide"]})],gt.prototype,"listMode",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],gt.prototype,"isReference",void 0),(0,r._)([(0,l.Cb)({type:["ArcGISImageServiceLayer"],json:{origins:{"web-map":{type:["ArcGISImageServiceLayer","ArcGISImageServiceVectorLayer"],read:!1,write:{target:"layerType",ignoreOrigin:!0}}}}})],gt.prototype,"operationalLayerType",void 0),(0,r._)([(0,c.c)("web-map","operationalLayerType")],gt.prototype,"writeOperationalLayerType",null),(0,r._)([(0,l.Cb)(S.C_)],gt.prototype,"popupEnabled",void 0),(0,r._)([(0,l.Cb)({type:n.Z,json:{read:{source:"popupInfo"},write:{target:"popupInfo"}}})],gt.prototype,"popupTemplate",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],gt.prototype,"defaultPopupTemplate",null),(0,r._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],gt.prototype,"type",void 0),gt=(0,r._)([(0,p.j)("esri.layers.ImageryLayer")],gt);const bt=gt},17287:(e,t,i)=>{i.d(t,{Y:()=>u});var r=i(43697),n=i(92604),s=i(70586),o=i(5600),a=(i(67676),i(75215),i(52011)),l=i(66677);const u=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,l.Qc)(this.url);if((0,s.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,l.Nm)(e,n.Z.getLogger(this.declaredClass)))}};return(0,r._)([(0,o.Cb)()],t.prototype,"title",null),(0,r._)([(0,o.Cb)({type:String})],t.prototype,"url",null),t=(0,r._)([(0,a.j)("esri.layers.mixins.ArcGISService")],t),t}},60199:(e,t,i)=>{i.d(t,{D:()=>s});var r=i(66677);const n=[];function s(e,t){if((0,r.M8)(e.url??""))return!0;const{wkid:i}=t;for(const t of n){if((e.version??0)>=t[0])return!0;if("function"==typeof t[1]&&(t[1]=t[1]()),t[1].has(i))return!1}return!0}n.push([10.91,()=>{const e=new Set([9709,9716,9741,9761,9766]);for(let t=9712;t<=9713;t++)e.add(t);for(let t=9748;t<=9749;t++)e.add(t);for(let t=20904;t<=20932;t++)e.add(t);for(let t=21004;t<=21032;t++)e.add(t);for(let t=21207;t<=21264;t++)e.add(t);for(let t=21307;t<=21364;t++)e.add(t);for(let t=102759;t<=102760;t++)e.add(t);for(let t=102901;t<=102955;t++)e.add(t);return e}]),n.push([10.9,()=>{const e=new Set([9300,9354,9364,9367,9373,9377,9387,9456,9473,9498,9678,9680,29874,103599,103872,104028]);for(let t=9356;t<=9360;t++)e.add(t);for(let t=9404;t<=9407;t++)e.add(t);for(let t=9476;t<=9482;t++)e.add(t);for(let t=9487;t<=9494;t++)e.add(t);for(let t=9697;t<=9699;t++)e.add(t);return e}]),n.push([10.81,()=>{const e=new Set([9265,9333,103598,103699]);for(let t=9248;t<=9254;t++)e.add(t);for(let t=9271;t<=9273;t++)e.add(t);for(let t=9284;t<=9285;t++)e.add(t);for(let t=21453;t<=21463;t++)e.add(t);return e}]),n.push([10.8,()=>{const e=new Set([8088,8395,8428,8433,8531,8687,8692,8694,8699,8900,9003,9006,9009,9012,9017,9191]);for(let t=8035;t<=8036;t++)e.add(t);for(let t=8455;t<=8456;t++)e.add(t);for(let t=8518;t<=8529;t++)e.add(t);for(let t=8533;t<=8536;t++)e.add(t);for(let t=8538;t<=8540;t++)e.add(t);for(let t=8677;t<=8679;t++)e.add(t);for(let t=8902;t<=8903;t++)e.add(t);for(let t=8907;t<=8910;t++)e.add(t);for(let t=8949;t<=8951;t++)e.add(t);for(let t=8972;t<=8987;t++)e.add(t);for(let t=9039;t<=9040;t++)e.add(t);for(let t=9068;t<=9069;t++)e.add(t);for(let t=9140;t<=9141;t++)e.add(t);for(let t=9148;t<=9150;t++)e.add(t);for(let t=9153;t<=9159;t++)e.add(t);for(let t=9205;t<=9218;t++)e.add(t);for(let t=9221;t<=9222;t++)e.add(t);for(let t=54098;t<=54101;t++)e.add(t);return e}]),n.push([10.71,()=>{const e=new Set([6316]);for(let t=8351;t<=8353;t++)e.add(t);for(let t=9294;t<=9297;t++)e.add(t);for(let t=103586;t<=103594;t++)e.add(t);for(let t=103696;t<=103698;t++)e.add(t);return e}]),n.push([10.7,()=>{const e=new Set([8387,8391,8427,8545,8682,8685,8818,31370,104022,104024,104975]);for(let t=8065;t<=8068;t++)e.add(t);for(let t=8082;t<=8083;t++)e.add(t);for(let t=8379;t<=8385;t++)e.add(t);for(let t=8836;t<=8840;t++)e.add(t);for(let t=8857;t<=8860;t++)e.add(t);for(let t=53035;t<=53037;t++)e.add(t);for(let t=54090;t<=54091;t++)e.add(t);for(let t=102498;t<=102499;t++)e.add(t);return e}]),n.push([10.61,()=>new Set([102497])]),n.push([10.6,()=>{const e=new Set([7803,7805,7887,8086,8232,8237,8240,8246,8249,8252,8255,9019,9391]);for(let t=7755;t<=7787;t++)e.add(t);for(let t=7791;t<=7795;t++)e.add(t);for(let t=7799;t<=7801;t++)e.add(t);for(let t=7825;t<=7831;t++)e.add(t);for(let t=7877;t<=7878;t++)e.add(t);for(let t=7882;t<=7883;t++)e.add(t);for(let t=7991;t<=7992;t++)e.add(t);for(let t=8042;t<=8043;t++)e.add(t);for(let t=8058;t<=8059;t++)e.add(t);for(let t=8311;t<=8348;t++)e.add(t);for(let t=9060;t<=9067;t++)e.add(t);for(let t=102562;t<=102568;t++)e.add(t);for(let t=102799;t<=102900;t++)e.add(t);return e}]),n.push([10.51,()=>{const e=new Set([7683,7881,7886,7899,8888,9e3]);for(let t=8013;t<=8032;t++)e.add(t);for(let t=9053;t<=9057;t++)e.add(t);for(let t=104017;t<=104018;t++)e.add(t);for(let t=104971;t<=104974;t++)e.add(t);return e}]),n.push([10.5,()=>{const e=new Set([6962,7035,7037,7039,7041,7084,7086,7133,7798,102399]);for(let t=4087;t<=4088;t++)e.add(t);for(let t=5896;t<=5899;t++)e.add(t);for(let t=7005;t<=7007;t++)e.add(t);for(let t=7057;t<=7070;t++)e.add(t);for(let t=7073;t<=7082;t++)e.add(t);for(let t=7109;t<=7128;t++)e.add(t);for(let t=7844;t<=7859;t++)e.add(t);return e}])},41818:(e,t,i)=>{i.d(t,{P:()=>o});var r=i(11282),n=i(34599),s=i(57444);async function o(e,t,i){const o=(0,r.en)(e);return(0,n.executeQueryForCount)(o,s.Z.from(t),{...i}).then((e=>e.data.count))}},5396:(e,t,i)=>{i.d(t,{G:()=>o});var r=i(11282),n=i(34599),s=i(57444);async function o(e,t,i){const o=(0,r.en)(e);return(0,n.executeQueryForIds)(o,s.Z.from(t),{...i}).then((e=>e.data.objectIds))}},4967:(e,t,i)=>{i.d(t,{F:()=>l,e:()=>a});var r=i(11282),n=i(34599),s=i(74889),o=i(57444);async function a(e,t,i){const r=await l(e,t,i);return s.default.fromJSON(r)}async function l(e,t,i){const s=(0,r.en)(e),a={...i},l=o.Z.from(t),{data:u}=await(0,n.executeQuery)(s,l,l.sourceSpatialReference,a);return u}},28694:(e,t,i)=>{i.d(t,{p:()=>s});var r=i(70586),n=i(69285);function s(e,t,i){if(!i||!i.features||!i.hasZ)return;const s=(0,n.k)(i.geometryType,t,e.outSpatialReference);if(!(0,r.Wi)(s))for(const e of i.features)s(e.geometry)}},98326:(e,t,i)=>{i.d(t,{Z:()=>c});var r,n=i(43697),s=i(96674),o=i(5600),a=(i(67676),i(75215)),l=i(52011);const u={1:{id:1,rotation:0,mirrored:!1},2:{id:2,rotation:0,mirrored:!0},3:{id:3,rotation:180,mirrored:!1},4:{id:4,rotation:180,mirrored:!0},5:{id:5,rotation:-90,mirrored:!0},6:{id:6,rotation:90,mirrored:!1},7:{id:7,rotation:90,mirrored:!0},8:{id:8,rotation:-90,mirrored:!1}};let p=r=class extends s.wq{constructor(e){super(e),this.contentType=null,this.exifInfo=null,this.id=null,this.globalId=null,this.keywords=null,this.name=null,this.parentGlobalId=null,this.parentObjectId=null,this.size=null,this.url=null}get orientationInfo(){const{exifInfo:e}=this,t=function(e){const{exifInfo:t,exifName:i,tagName:r}=e;if(!t||!i||!r)return null;const n=t.find((e=>e.name===i));return n?function(e){const{tagName:t,tags:i}=e;if(!i||!t)return null;const r=i.find((e=>e.name===t));return r&&r.value||null}({tagName:r,tags:n.tags}):null}({exifName:"Exif IFD0",tagName:"Orientation",exifInfo:e});return u[t]||null}clone(){return new r({contentType:this.contentType,exifInfo:this.exifInfo,id:this.id,globalId:this.globalId,keywords:this.keywords,name:this.name,parentGlobalId:this.parentGlobalId,parentObjectId:this.parentObjectId,size:this.size,url:this.url})}};(0,n._)([(0,o.Cb)({type:String})],p.prototype,"contentType",void 0),(0,n._)([(0,o.Cb)()],p.prototype,"exifInfo",void 0),(0,n._)([(0,o.Cb)({readOnly:!0})],p.prototype,"orientationInfo",null),(0,n._)([(0,o.Cb)({type:a.z8})],p.prototype,"id",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"globalId",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"keywords",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"name",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"parentGlobalId",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"parentObjectId",void 0),(0,n._)([(0,o.Cb)({type:a.z8})],p.prototype,"size",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"url",void 0),p=r=(0,n._)([(0,l.j)("esri.layers.support.AttachmentInfo")],p);const c=p},56545:(e,t,i)=>{i.d(t,{Z:()=>d});var r,n=i(43697),s=i(96674),o=i(22974),a=i(5600),l=i(75215),u=i(52011),p=i(30556);let c=r=class extends s.wq{constructor(e){super(e),this.attachmentTypes=null,this.attachmentsWhere=null,this.cacheHint=void 0,this.keywords=null,this.globalIds=null,this.name=null,this.num=null,this.objectIds=null,this.returnMetadata=!1,this.size=null,this.start=null,this.where=null}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10}clone(){return new r((0,o.d9)({attachmentTypes:this.attachmentTypes,attachmentsWhere:this.attachmentsWhere,cacheHint:this.cacheHint,keywords:this.keywords,where:this.where,globalIds:this.globalIds,name:this.name,num:this.num,objectIds:this.objectIds,returnMetadata:this.returnMetadata,size:this.size,start:this.start}))}};(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],c.prototype,"attachmentTypes",void 0),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"attachmentsDefinitionExpression"},write:{target:"attachmentsDefinitionExpression"}}})],c.prototype,"attachmentsWhere",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],c.prototype,"cacheHint",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],c.prototype,"keywords",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"globalIds",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],c.prototype,"name",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],c.prototype,"num",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"objectIds",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{default:!1,write:!0}})],c.prototype,"returnMetadata",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"size",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],c.prototype,"start",void 0),(0,n._)([(0,p.c)("start"),(0,p.c)("num")],c.prototype,"writeStart",null),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],c.prototype,"where",void 0),c=r=(0,n._)([(0,u.j)("esri.rest.support.AttachmentQuery")],c),c.from=(0,l.se)(c);const d=c},75935:(e,t,i)=>{i.d(t,{Z:()=>h});var r,n=i(43697),s=(i(66577),i(96674)),o=i(22974),a=i(5600),l=i(75215),u=i(52011),p=i(30556),c=i(10158),d=i(82971);let m=r=class extends s.wq{constructor(e){super(e),this.cacheHint=void 0,this.dynamicDataSource=void 0,this.gdbVersion=null,this.geometryPrecision=void 0,this.historicMoment=null,this.maxAllowableOffset=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.relationshipId=void 0,this.start=void 0,this.num=void 0,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.where=null}_writeHistoricMoment(e,t){t.historicMoment=e&&e.getTime()}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10,this.start>0&&null==this.where&&(t.definitionExpression="1=1")}clone(){return new r((0,o.d9)({cacheHint:this.cacheHint,dynamicDataSource:this.dynamicDataSource,gdbVersion:this.gdbVersion,geometryPrecision:this.geometryPrecision,historicMoment:this.historicMoment&&new Date(this.historicMoment.getTime()),maxAllowableOffset:this.maxAllowableOffset,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,relationshipId:this.relationshipId,start:this.start,num:this.num,returnGeometry:this.returnGeometry,where:this.where,returnZ:this.returnZ,returnM:this.returnM}))}};(0,n._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"cacheHint",void 0),(0,n._)([(0,a.Cb)({type:c.n,json:{write:!0}})],m.prototype,"dynamicDataSource",void 0),(0,n._)([(0,a.Cb)({type:String,json:{write:!0}})],m.prototype,"gdbVersion",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{write:!0}})],m.prototype,"geometryPrecision",void 0),(0,n._)([(0,a.Cb)({type:Date})],m.prototype,"historicMoment",void 0),(0,n._)([(0,p.c)("historicMoment")],m.prototype,"_writeHistoricMoment",null),(0,n._)([(0,a.Cb)({type:Number,json:{write:!0}})],m.prototype,"maxAllowableOffset",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],m.prototype,"objectIds",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],m.prototype,"orderByFields",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],m.prototype,"outFields",void 0),(0,n._)([(0,a.Cb)({type:d.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],m.prototype,"outSpatialReference",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],m.prototype,"relationshipId",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],m.prototype,"start",void 0),(0,n._)([(0,p.c)("start"),(0,p.c)("num")],m.prototype,"writeStart",null),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],m.prototype,"num",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],m.prototype,"returnGeometry",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"returnM",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"returnZ",void 0),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],m.prototype,"where",void 0),m=r=(0,n._)([(0,u.j)("esri.rest.support.RelationshipQuery")],m),m.from=(0,l.se)(m);const h=m},28141:(e,t,i)=>{i.d(t,{Z:()=>C});var r,n=i(43697),s=i(66577),o=i(92835),a=i(35454),l=i(96674),u=i(22974),p=i(70586),c=i(5600),d=i(75215),m=i(52011),h=i(30556),y=i(33955);i(67676);let f=r=class extends l.wq{constructor(e){super(e),this.groupByFields=void 0,this.topCount=void 0,this.orderByFields=void 0}clone(){return new r({groupByFields:this.groupByFields,topCount:this.topCount,orderByFields:this.orderByFields})}};(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],f.prototype,"groupByFields",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],f.prototype,"topCount",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],f.prototype,"orderByFields",void 0),f=r=(0,n._)([(0,m.j)("esri.rest.support.TopFilter")],f);const g=f;var b,R=i(82971);const v=new a.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),w=new a.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let _=b=class extends l.wq{constructor(e){super(e),this.cacheHint=void 0,this.distance=void 0,this.geometry=null,this.geometryPrecision=void 0,this.maxAllowableOffset=void 0,this.num=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.resultType=null,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.start=void 0,this.spatialRelationship="intersects",this.timeExtent=null,this.topFilter=void 0,this.units=null,this.where="1=1"}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10}clone(){return new b((0,u.d9)({cacheHint:this.cacheHint,distance:this.distance,geometry:this.geometry,geometryPrecision:this.geometryPrecision,maxAllowableOffset:this.maxAllowableOffset,num:this.num,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,resultType:this.resultType,returnGeometry:this.returnGeometry,returnZ:this.returnZ,returnM:this.returnM,start:this.start,spatialRelationship:this.spatialRelationship,timeExtent:this.timeExtent,topFilter:this.topFilter,units:this.units,where:this.where}))}};(0,n._)([(0,c.Cb)({type:Boolean,json:{write:!0}})],_.prototype,"cacheHint",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:{overridePolicy:e=>({enabled:e>0})}}})],_.prototype,"distance",void 0),(0,n._)([(0,c.Cb)({types:s.qM,json:{read:y.im,write:!0}})],_.prototype,"geometry",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],_.prototype,"geometryPrecision",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],_.prototype,"maxAllowableOffset",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],_.prototype,"num",void 0),(0,n._)([(0,c.Cb)({json:{write:!0}})],_.prototype,"objectIds",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],_.prototype,"orderByFields",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],_.prototype,"outFields",void 0),(0,n._)([(0,c.Cb)({type:R.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],_.prototype,"outSpatialReference",void 0),(0,n._)([(0,c.Cb)({type:String,json:{write:!0}})],_.prototype,"resultType",void 0),(0,n._)([(0,c.Cb)({json:{write:!0}})],_.prototype,"returnGeometry",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"returnM",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"returnZ",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],_.prototype,"start",void 0),(0,n._)([(0,h.c)("start"),(0,h.c)("num")],_.prototype,"writeStart",null),(0,n._)([(0,c.Cb)({type:String,json:{read:{source:"spatialRel",reader:v.read},write:{target:"spatialRel",writer:v.write}}})],_.prototype,"spatialRelationship",void 0),(0,n._)([(0,c.Cb)({type:o.Z,json:{write:!0}})],_.prototype,"timeExtent",void 0),(0,n._)([(0,c.Cb)({type:g,json:{write:!0}})],_.prototype,"topFilter",void 0),(0,n._)([(0,c.Cb)({type:String,json:{read:w.read,write:{writer:w.write,overridePolicy(e){return{enabled:(0,p.pC)(e)&&(0,p.pC)(this.distance)&&this.distance>0}}}}})],_.prototype,"units",void 0),(0,n._)([(0,c.Cb)({type:String,json:{write:!0}})],_.prototype,"where",void 0),_=b=(0,n._)([(0,m.j)("esri.rest.support.TopFeaturesQuery")],_),_.from=(0,d.se)(_);const C=_}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4028],{17445:(e,t,i)=>{i.d(t,{N1:()=>d,YP:()=>l,Z_:()=>y,gx:()=>u,nn:()=>f,on:()=>c,tX:()=>g});var r=i(91460),n=i(50758),s=i(70586),o=i(95330),a=i(26258);function l(e,t,i={}){return p(e,t,i,m)}function u(e,t,i={}){return p(e,t,i,h)}function p(e,t,i={},r){let n=null;const o=i.once?(e,i)=>{r(e)&&((0,s.hw)(n),t(e,i))}:(e,i)=>{r(e)&&t(e,i)};if(n=(0,a.aQ)(e,o,i.sync,i.equals),i.initial){const t=e();o(t,t)}return n}function c(e,t,i,o={}){let a=null,u=null,p=null;function c(){a&&u&&(u.remove(),o.onListenerRemove?.(a),a=null,u=null)}function d(e){o.once&&o.once&&(0,s.hw)(p),i(e)}const m=l(e,((e,i)=>{c(),(0,r.vT)(e)&&(a=e,u=(0,r.on)(e,t,d),o.onListenerAdd?.(e))}),{sync:o.sync,initial:!0});return p=(0,n.kB)((()=>{m.remove(),c()})),p}function d(e,t){return function(e,t,i){if((0,o.Hc)(i))return Promise.reject((0,o.zE)());const r=e();if(t?.(r))return Promise.resolve(r);let a=null;function l(){a=(0,s.hw)(a)}return new Promise(((r,s)=>{a=(0,n.AL)([(0,o.fu)(i,(()=>{l(),s((0,o.zE)())})),p(e,(e=>{l(),r(e)}),{sync:!1,once:!0},t??m)])}))}(e,h,t)}function m(e){return!0}function h(e){return!!e}i(87538);const y={sync:!0},f={initial:!0},g={sync:!0,initial:!0}},66210:(e,t,i)=>{i.r(t),i.d(t,{default:()=>bt});var r=i(43697),n=i(51773),s=i(70586),o=i(16453),a=i(95330),l=i(5600),u=(i(67676),i(75215)),p=i(52011),c=i(30556),d=i(87085),m=i(66577),h=i(38171),y=i(30030),f=i(3172),g=i(20102),b=i(35454),R=i(22974),v=i(92604),w=i(17445),_=i(17452),C=i(71715),S=i(21506),x=i(35956),I=i(96674),F=i(40297);const T={StretchFunction:{arguments:{ComputeGamma:{isDataset:!1,isPublic:!1,name:"ComputeGamma",type:"RasterFunctionVariable",value:!1},DRA:{isDataset:!1,isPublic:!1,name:"DRA",type:"RasterFunctionVariable",value:!1},EstimateStatsHistogram:{isDataset:!1,isPublic:!1,name:"EstimateStatsHistogram",type:"RasterFunctionVariable",value:!1},Gamma:{displayName:"Gamma",isDataset:!1,isPublic:!1,name:"Gamma",type:"RasterFunctionVariable"},Histograms:{isDataset:!1,isPublic:!1,name:"Histograms",type:"RasterFunctionVariable"},Max:{isDataset:!1,isPublic:!1,name:"Max",type:"RasterFunctionVariable",value:255},MaxPercent:{isDataset:!1,isPublic:!1,name:"MaxPercent",type:"RasterFunctionVariable",value:.5},Min:{isDataset:!1,isPublic:!1,name:"Min",type:"RasterFunctionVariable",value:0},MinPercent:{isDataset:!1,isPublic:!1,name:"MinPercent",type:"RasterFunctionVariable",value:.25},NumberOfStandardDeviations:{isDataset:!1,isPublic:!1,name:"NumberOfStandardDeviation",type:"RasterFunctionVariable",value:2},Raster:{isDataset:!0,isPublic:!1,name:"Raster",type:"RasterFunctionVariable"},SigmoidStrengthLevel:{isDataset:!1,isPublic:!1,name:"SigmoidStrengthLevel",type:"RasterFunctionVariable",value:2},Statistics:{isDataset:!1,isPublic:!1,name:"Statistics",type:"RasterFunctionVariable"},StretchType:{isDataset:!1,isPublic:!1,name:"StretchType",type:"RasterFunctionVariable",value:0},type:"StretchFunctionArguments",UseGamma:{isDataset:!1,isPublic:!1,name:"UseGamma",type:"RasterFunctionVariable",value:!1}},description:"Enhances an image by adjusting the range of values displayed. This does not alter the underlying pixel values. If a pixel has a value outside of the specified range, it will appear as either the minimum or maximum value.",function:{description:"Enhances an image by adjusting the range of values displayed. This does not alter the underlying pixel values. If a pixel has a value outside of the specified range, it will appear as either the minimum or maximum value.",name:"Stretch",pixelType:"UNKNOWN",type:"StretchFunction"},functionType:0,name:"Stretch",thumbnail:""},RemapFunction:{name:"Remap",description:"Changes pixel values by assigning new values to ranges of pixel values or using an external table.",function:{type:"RemapFunction",pixelType:"UNKNOWN",name:"Remap",description:"Changes pixel values by assigning new values to ranges of pixel values or using an external table."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},UseTable:{name:"UseTable",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},InputRanges:{name:"InputRanges",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"Input Ranges"},OutputValues:{name:"OutputValues",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"Output Values"},NoDataRanges:{name:"NoDataRanges",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable",displayName:"NoData Ranges"},Table:{name:"Table",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},InputField:{name:"InputField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},OutputField:{name:"OutputField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},InputMaxField:{name:"InputMaxField",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},RemapTableType:{name:"RemapTableType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},AllowUnmatched:{name:"AllowUnmatched",isPublic:!1,isDataset:!1,value:!0,type:"RasterFunctionVariable"},type:"RemapFunctionArguments"},functionType:0,thumbnail:""},ColormapFunction:{name:"Colormap",description:"Changes pixel values to display the raster data as either a grayscale or a red, green, blue (RGB) image, based on a colormap or a color ramp.",function:{type:"ColormapFunction",pixelType:"UNKNOWN",name:"Colormap",description:"Changes pixel values to display the raster data as either a grayscale or a red, green, blue (RGB) image, based on a colormap or a color ramp."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ColorSchemeType:{name:"ColorSchemeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},Colormap:{name:"Colormap",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},ColormapName:{name:"ColormapName",isPublic:!1,isDataset:!1,value:"Gray",type:"RasterFunctionVariable"},ColorRamp:{name:"ColorRamp",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},type:"ColormapFunctionArguments"},functionType:0,thumbnail:""},ShadedReliefFunction:{name:"Shaded Relief",description:"Creates a multiband, color coded, 3D representation of the surface, with the sun's relative position taken into account for shading the image.",function:{type:"ShadedReliefFunction",pixelType:"UNKNOWN",name:"Shaded Relief",description:"Creates a multiband, color coded, 3D representation of the surface, with the sun's relative position taken into account for shading the image."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ColorSchemeType:{name:"ColorSchemeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ColorRamp:{name:"ColorRamp",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},HillshadeType:{name:"HillshadeType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},Colormap:{name:"Colormap",isPublic:!1,isDataset:!1,type:"RasterFunctionVariable"},Azimuth:{name:"Azimuth",isPublic:!1,isDataset:!1,value:315,type:"RasterFunctionVariable"},Altitude:{name:"Altitude",isPublic:!1,isDataset:!1,value:45,type:"RasterFunctionVariable"},SlopeType:{name:"SlopeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ZFactor:{name:"ZFactor",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},PSPower:{name:"PSPower",isPublic:!1,isDataset:!1,value:.664,type:"RasterFunctionVariable"},PSZFactor:{name:"PSZFactor",isPublic:!1,isDataset:!1,value:.024,type:"RasterFunctionVariable"},RemoveEdgeEffect:{name:"RemoveEdgeEffect",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},type:"ShadedReliefFunctionArguments"},functionType:0,thumbnail:""},HillshadeFunction:{name:"Hillshade",description:"Creates a 3D representation of the surface, with the sun's relative position taken into account for shading the image",function:{type:"HillshadeFunction",pixelType:"UNKNOWN",name:"Hillshade",description:"Creates a 3D representation of the surface, with the sun's relative position taken into account for shading the image"},arguments:{DEM:{name:"DEM",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},HillshadeType:{name:"HillshadeType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},Azimuth:{name:"Azimuth",isPublic:!1,isDataset:!1,value:315,type:"RasterFunctionVariable"},Altitude:{name:"Altitude",isPublic:!1,isDataset:!1,value:45,type:"RasterFunctionVariable"},SlopeType:{name:"SlopeType",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},ZFactor:{name:"ZFactor",isPublic:!1,isDataset:!1,value:1,type:"RasterFunctionVariable"},PSPower:{name:"PSPower",isPublic:!1,isDataset:!1,value:.664,type:"RasterFunctionVariable"},PSZFactor:{name:"PSZFactor",isPublic:!1,isDataset:!1,value:.024,type:"RasterFunctionVariable"},RemoveEdgeEffect:{name:"RemoveEdgeEffect",isPublic:!1,isDataset:!1,value:!1,type:"RasterFunctionVariable"},type:"HillshadeFunctionArguments"},functionType:0,thumbnail:""},ResampleFunction:{name:"Resample",description:"Changes the cell size of a raster.",function:{type:"ResampleFunction",pixelType:"UNKNOWN",name:"Resample",description:"Changes the cell size of a raster."},arguments:{Raster:{name:"Raster",isPublic:!1,isDataset:!0,type:"RasterFunctionVariable"},ResamplingType:{name:"ResamplingType",isPublic:!1,isDataset:!1,value:0,type:"RasterFunctionVariable"},InputCellSize:{name:"InputCellsize",isPublic:!1,isDataset:!1,value:{x:0,y:0},type:"RasterFunctionVariable"},OutputCellSize:{name:"OutputCellsize",isPublic:!1,isDataset:!1,value:{x:0,y:0},type:"RasterFunctionVariable"},type:"ResampleFunctionArguments"},functionType:0,thumbnail:""}};var N=i(93010),D=i(75509),j=i(23847);const P={u1:[0,1],u2:[0,3],u4:[0,15],u8:[0,255],s8:[-128,127],u16:[0,65535],s16:[-32768,32767]},O={simple_scalar:"Simple Scalar",wind_barb:"Wind Barb",single_arrow:"Single Arrow",beaufort_kn:"Beaufort Wind (Knots)",beaufort_m:"Beaufort Wind (MetersPerSecond)",ocean_current_m:"Ocean Current (MetersPerSecond)",ocean_current_kn:"Ocean Current (Knots)"},M=new Set(["raster-stretch","unique-value","class-breaks","raster-shaded-relief","vector-field","raster-colormap"]);function V(e){return M.has(e.type)}function A(e,t){if(!e||!t)return(0,R.d9)(e||t);const i=(0,R.d9)(e);if(t.rasterFunctionDefinition){const e=t.rasterFunctionDefinition;(e.thumbnail||e.thumbnailEx)&&(e.thumbnail=e.thumbnailEx=null),J(i.rasterFunctionDefinition.arguments,t)}else"none"!==t.functionName.toLowerCase()&&(E(i.functionArguments).Raster=t);return i}function J(e,t){for(const i in e)"raster"===i.toLowerCase()&&("RasterFunctionVariable"===e[i].type?(e[i]=t.rasterFunctionDefinition,e[i].type="RasterFunctionTemplate"):"RasterFunctionTemplate"===e[i].type&&J(e[i].arguments,t))}function Z(e){const t=(0,R.d9)(T[e.functionName+"Function"]),i=e.functionArguments;for(const e in i)"raster"===e.toLowerCase()?(t.arguments[e]=Z(i[e]),t.arguments[e].type="RasterFunctionTemplate"):"colormap"===e.toLowerCase()?(t.arguments[e].value=k(i[e]),t.arguments.ColorSchemeType.value=0):t.arguments[e].value=i[e];return t}function E(e){const t=e?.Raster;return t&&"esri.layers.support.RasterFunction"===t.declaredClass?E(t.functionArguments):e}const q={none:0,standardDeviation:3,histogramEqualization:4,minMax:5,percentClip:6,sigmoid:9};function z(e,t){const i=P[String(t).toLowerCase()];return i&&e.push([Math.floor(i[0]-1),0,0,0],[Math.ceil(i[1]+1),0,0,0]),e}function L(e){if((0,s.Wi)(e))return;const{fields:t}=e,i=t&&t.find((e=>e&&e.name&&"value"===e.name.toLowerCase()));return i&&i.name}function H(e){const t=[];return e.forEach((e=>{const i=e;if(Array.isArray(i))t.push(i);else{if(null==i.min||null==i.max)return;const e=[i.min,i.max,i.avg||0,i.stddev||0];t.push(e)}})),t}function k(e){const t=[],i=[];return e.forEach((e=>{t.push(e[0]),i.push((0,N.io)([...e.slice(1),255]))})),{type:"RasterColormap",values:t,colors:i}}var B,G=i(90578),Q=i(94139);const U=(0,b.w)()({MT_FIRST:"first",MT_LAST:"last",MT_MIN:"min",MT_MAX:"max",MT_MEAN:"mean",MT_BLEND:"blend",MT_SUM:"sum"}),W=(0,b.w)()({esriMosaicNone:"none",esriMosaicCenter:"center",esriMosaicNadir:"nadir",esriMosaicViewpoint:"viewpoint",esriMosaicAttribute:"attribute",esriMosaicLockRaster:"lock-raster",esriMosaicNorthwest:"northwest",esriMosaicSeamline:"seamline"});let $=B=class extends I.wq{constructor(e){super(e),this.ascending=!0,this.itemRenderingRule=null,this.lockRasterIds=null,this.method=null,this.multidimensionalDefinition=null,this.objectIds=null,this.operation=null,this.sortField=null,this.sortValue=null,this.viewpoint=null,this.where=null}readAscending(e,t){return null!=t.ascending?t.ascending:null==t.sortAscending||t.sortAscending}readMethod(e,t){return function(e){let t;switch(e?e.toLowerCase().replace("esrimosaic",""):""){case"byattribute":case"attribute":t="esriMosaicAttribute";break;case"lockraster":t="esriMosaicLockRaster";break;case"center":t="esriMosaicCenter";break;case"northwest":t="esriMosaicNorthwest";break;case"nadir":t="esriMosaicNadir";break;case"viewpoint":t="esriMosaicViewpoint";break;case"seamline":t="esriMosaicSeamline";break;default:t="esriMosaicNone"}return W.fromJSON(t)}(t.mosaicMethod||t.defaultMosaicMethod)}readOperation(e,t){const i=t.mosaicOperation,r=t.mosaicOperator&&t.mosaicOperator.toLowerCase(),n=i||(r?U.toJSON(r):null);return U.fromJSON(n)||"first"}castSortValue(e){return null==e||"string"==typeof e||"number"==typeof e?e:`${e}`}clone(){return new B({ascending:this.ascending,itemRenderingRule:(0,R.d9)(this.itemRenderingRule),lockRasterIds:(0,R.d9)(this.lockRasterIds),method:this.method,multidimensionalDefinition:(0,R.d9)(this.multidimensionalDefinition),objectIds:(0,R.d9)(this.objectIds),operation:this.operation,sortField:this.sortField,sortValue:this.sortValue,viewpoint:(0,R.d9)(this.viewpoint),where:this.where})}};(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],$.prototype,"ascending",void 0),(0,r._)([(0,C.r)("ascending",["ascending","sortAscending"])],$.prototype,"readAscending",null),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],$.prototype,"itemRenderingRule",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{write:{overridePolicy(){return{enabled:"lock-raster"===this.method}}}}})],$.prototype,"lockRasterIds",void 0),(0,r._)([(0,l.Cb)({type:String,json:{type:W.jsonValues,write:{target:"mosaicMethod",writer:W.write}}})],$.prototype,"method",void 0),(0,r._)([(0,C.r)("method",["mosaicMethod","defaultMosaicMethod"])],$.prototype,"readMethod",null),(0,r._)([(0,l.Cb)({type:[x.Z],json:{write:!0}})],$.prototype,"multidimensionalDefinition",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{name:"fids",write:!0}})],$.prototype,"objectIds",void 0),(0,r._)([(0,l.Cb)({json:{type:U.jsonValues,read:{reader:U.read},write:{target:"mosaicOperation",writer:U.write}}})],$.prototype,"operation",void 0),(0,r._)([(0,C.r)("operation",["mosaicOperation","mosaicOperator"])],$.prototype,"readOperation",null),(0,r._)([(0,l.Cb)({type:String,json:{write:{overridePolicy(){return{enabled:"attribute"===this.method}}}}})],$.prototype,"sortField",void 0),(0,r._)([(0,l.Cb)({type:[String,Number],json:{write:{allowNull:!0,overridePolicy(){return{enabled:"attribute"===this.method,allowNull:!0}}}}})],$.prototype,"sortValue",void 0),(0,r._)([(0,G.p)("sortValue")],$.prototype,"castSortValue",null),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],$.prototype,"viewpoint",void 0),(0,r._)([(0,l.Cb)({type:String,json:{write:!0}})],$.prototype,"where",void 0),$=B=(0,r._)([(0,p.j)("esri.layers.support.MosaicRule")],$);const K=$;var X=i(69608);let Y=class extends I.wq{constructor(){super(...arguments),this.layer=null,this.adjustAspectRatio=void 0,this.compression=void 0,this.pixelType=void 0,this.lercVersion=2}writeAdjustAspectRatio(e,t,i){this.layer.version<10.3||(t[i]=e)}get bandIds(){return this.layer.bandIds}set bandIds(e){this.layer&&(this.layer.bandIds=e)}get compressionQuality(){return this.layer?.compressionQuality}set compressionQuality(e){this.layer&&(this.layer.compressionQuality=e)}writeCompressionQuality(e,t,i){this.format&&this.format.toLowerCase().includes("jpg")&&null!=e&&(t[i]=e)}get compressionTolerance(){return this.layer?.compressionTolerance}set compressionTolerance(e){this.layer&&(this.layer.compressionTolerance=e)}writeCompressionTolerance(e,t,i){"lerc"===this.format&&null!=e&&(t[i]=e)}get format(){return"vector-field"===this.layer.renderer?.type?"lerc":this.layer.format}get interpolation(){return this.layer?.interpolation}set interpolation(e){this.layer&&(this.layer.interpolation=e)}get noData(){return this.layer?.noData}set noData(e){this.layer&&(this.layer.noData=e)}get noDataInterpretation(){return this.layer?.noDataInterpretation}set noDataInterpretation(e){this.layer&&(this.layer.noDataInterpretation=e)}writeLercVersion(e,t,i){"lerc"===this.format&&this.layer.version>=10.5&&(t[i]=e)}get version(){const e=this.layer;return e.commitProperty("bandIds"),e.commitProperty("format"),e.commitProperty("compressionQuality"),e.commitProperty("compressionTolerance"),e.commitProperty("interpolation"),e.commitProperty("noData"),e.commitProperty("noDataInterpretation"),e.commitProperty("mosaicRule"),e.commitProperty("renderingRule"),e.commitProperty("adjustAspectRatio"),e.commitProperty("pixelFilter"),e.commitProperty("definitionExpression"),e.commitProperty("multidimensionalSubset"),(this._get("version")||0)+1}set version(e){this._set("version",e)}get mosaicRule(){const e=this.layer;let t=e.mosaicRule;const i=e.definitionExpression;return t?i&&i!==t.where&&(t=t.clone(),t.where=i):i&&(t=new K({where:i})),t}get renderingRule(){const e=this.layer;let t=e.renderingRule;const i=e.pixelFilter,r=!e.format||e.format.includes("jpg")||e.format.includes("png");t=this._addResampleRasterFunction(t);const n=e.multidimensionalSubset?.areaOfInterest;return n&&(t=this._addClipFunction(t,n)),r&&!i&&"vector-field"!==e.renderer?.type&&(t=this.combineRendererWithRenderingRule(t)),t}combineRendererWithRenderingRule(e){const t=this.layer,{rasterInfo:i,renderer:r}=t;return e=e||t.renderingRule,r&&V(r)?A(function(e,t){switch(t=t||{},e.type){case"raster-stretch":return function(e,t){const i=t.convertToRFT,r=new F.Z;r.functionName="Stretch";const n=q[D.v.toJSON(e.stretchType)],s="u8",o={StretchType:n,Statistics:H(e.statistics),DRA:e.dynamicRangeAdjustment,UseGamma:e.useGamma,Gamma:e.gamma,ComputeGamma:e.computeGamma};if(null!=e.outputMin&&(o.Min=e.outputMin),null!=e.outputMax&&(o.Max=e.outputMax),n===q.standardDeviation?(o.NumberOfStandardDeviations=e.numberOfStandardDeviations,r.outputPixelType=s):n===q.percentClip?(o.MinPercent=e.minPercent,o.MaxPercent=e.maxPercent,r.outputPixelType=s):n===q.minMax?r.outputPixelType=s:n===q.sigmoid&&(o.SigmoidStrengthLevel=e.sigmoidStrengthLevel),r.functionArguments=o,r.variableName="Raster",e.colorRamp){const n=e.colorRamp,s=new F.Z;if(i)s.functionArguments={ColorRamp:(0,N.pM)(n)};else{const i=(0,N.Uh)(n);if(i)s.functionArguments={colorRamp:i};else if(!t.convertColorRampToColormap||"algorithmic"!==n.type&&"multipart"!==n.type){const t=e.colorRamp.toJSON();"algorithmic"===t.type?t.algorithm=t.algorithm||"esriCIELabAlgorithm":"multipart"===t.type&&t.colorRamps?.length&&t.colorRamps.forEach((e=>e.algorithm=e.algorithm||"esriCIELabAlgorithm")),s.functionArguments={colorRamp:t}}else s.functionArguments={Colormap:(0,N.Jw)(n,256)}}return s.variableName="Raster",s.functionName="Colormap",s.functionArguments.Raster=r,i?new F.Z({rasterFunctionDefinition:Z(s)}):s}return i?new F.Z({rasterFunctionDefinition:Z(r)}):r}(e,t);case"class-breaks":return function(e,t){const i=[],r=[],n=[],o=[],a=1e-6,{pixelType:l,rasterAttributeTable:u}=t,p=(0,s.Wi)(u)?null:u.features,c=L(u);if(p&&Array.isArray(p)&&e.classBreakInfos){e.classBreakInfos.forEach(((t,i)=>{const r=t.symbol.color;let n;r.a&&p.forEach((s=>{n=s.attributes[e.field],(n>=t.minValue&&n<t.maxValue||i===e.classBreakInfos.length-1&&n>=t.minValue)&&o.push([s.attributes[c],r.r,r.g,r.b])}))}));const i=l?z(o,l):o,r=new F.Z;return r.functionName="Colormap",r.functionArguments={},r.functionArguments.Colormap=i,r.variableName="Raster",t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(r)}):r}e.classBreakInfos.forEach(((e,t)=>{const s=e.symbol&&e.symbol.color;s.a?(0===t?i.push(e.minValue,e.maxValue+a):i.push(e.minValue+a,e.maxValue+a),r.push(t),o.push([t,s.r,s.g,s.b])):n.push(e.minValue,e.maxValue)}));const d=l?z(o,l):o,m=new F.Z;m.functionName="Remap",m.functionArguments={InputRanges:i,OutputValues:r,NoDataRanges:n},m.variableName="Raster";const h=new F.Z;return h.functionName="Colormap",h.functionArguments={Colormap:d,Raster:m},t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(h)}):h}(e,t);case"unique-value":return function(e,t){const i=[],{pixelType:r,rasterAttributeTable:n}=t,o=(0,s.Wi)(n)?null:n.features,a=L(n),l=e.defaultSymbol?.color?.toRgb(),u=e.uniqueValueInfos;if(u)if(o){const t=new Map;u.forEach((e=>{const i=e.value,r=e.symbol.color;null!=i&&r&&r.a&&t.set(String(i),r.toRgb())}));const r=e.field;o.forEach((({attributes:e})=>{const n=String(e[r]),s=e[a];if(t.has(n)){const e=t.get(n);i.push([s,...e])}else l&&i.push([s,...l])}))}else for(let e=0;e<u.length;e++){const t=u[e],r=t.symbol.color,n=+t.value;if(r?.a){if(isNaN(n))return null;i.push([n,r.r,r.g,r.b])}}const p=r&&i.length>0?z(i,r):i,c=new F.Z;return c.functionName="Colormap",c.functionArguments={},c.functionArguments.Colormap=p,c.variableName="Raster",t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(c)}):c}(e,t);case"raster-colormap":return function(e,t){const i=e.extractColormap();if(!i||0===i.length)return;const{pixelType:r}=t,n=r?z(i,r):i,s=new F.Z;return s.functionName="Colormap",s.functionArguments={},s.functionArguments.Colormap=n,t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(s)}):s}(e,t);case"vector-field":return function(e,t){const i=new F.Z;i.functionName="VectorFieldRenderer";const{dataType:r,bandProperties:n}=t,s="vector-uv"===r;let o,a;n&&2===n.length&&(o=n.map((e=>e.BandName.toLowerCase())).indexOf("magnitude"),a=n.map((e=>e.BandName.toLowerCase())).indexOf("direction")),-1!==o&&null!==o||(o=0,a=1);const l="arithmetic"===e.rotationType?1:2,u="flow-from"===e.flowRepresentation?0:1,p=e.visualVariables?e.visualVariables.find((e=>"Magnitude"===e.field)):new j.Z,c={magnitudeBandID:o,directionBandID:a,isUVComponents:s,referenceSystem:l,massFlowAngleRepresentation:u,symbolTileSize:50,symbolTileSizeUnits:100,calculationMethod:"Vector Average",symbologyName:O[e.style.toLowerCase().replace("-","_")],minimumMagnitude:p.minDataValue,maximumMagnitude:p.maxDataValue,minimumSymbolSize:p.minSize,maximumSymbolSize:p.maxSize};return i.functionArguments=c,t.convertToRFT?new F.Z({rasterFunctionDefinition:Z(i)}):i}(e,t);case"raster-shaded-relief":return function(e,t){const i=t.convertToRFT;if("elevation"!==t.dataType&&("generic"!==t.dataType||1!==t.bandCount||"s16"!==t.pixelType&&"s32"!==t.pixelType&&"f32"!==t.pixelType&&"f64"!==t.pixelType))return new F.Z;const r=new F.Z;r.functionName="Hillshade";const n="traditional"===e.hillshadeType?0:1,s="none"===e.scalingType?1:3,o={HillshadeType:n,SlopeType:s,ZFactor:e.zFactor};return 0===n&&(o.Azimuth=e.azimuth,o.Altitude=e.altitude),3===s&&(o.PSPower=e.pixelSizePower,o.PSZFactor=e.pixelSizeFactor),r.functionArguments=o,r.variableName="Raster",e.colorRamp&&(r.functionName="ShadedRelief",i?o.ColorRamp=(0,N.pM)(e.colorRamp):o.Colormap=(0,N.Jw)(e.colorRamp,256)),i?new F.Z({rasterFunctionDefinition:Z(r)}):r}(e,t);case"flow":throw new Error("Unsupported rendering rule.")}}(r,{rasterAttributeTable:i.attributeTable,pixelType:i.pixelType,dataType:i.dataType,bandProperties:i.keyProperties?.BandProperties,convertColorRampToColormap:t.version<10.6,convertToRFT:!!e?.rasterFunctionDefinition,bandCount:i.bandCount}),e):e}_addResampleRasterFunction(e){if("vector-field"!==this.layer.renderer?.type||"Resample"===e?.functionName)return e;const t="esriImageServiceDataTypeVector-UV"===this.layer.serviceDataType?7:10,i=this.layer.serviceRasterInfo.pixelSize;let r=new F.Z({functionName:"Resample",functionArguments:{ResamplingType:t,InputCellSize:i}});return r=e?.rasterFunctionDefinition?new F.Z({rasterFunctionDefinition:Z(r)}):r,A(r,e)}_addClipFunction(e,t){return A(new F.Z({functionName:"Clip",functionArguments:{ClippingGeometry:t.toJSON(),ClippingType:1}}),e)}};(0,r._)([(0,l.Cb)()],Y.prototype,"layer",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"adjustAspectRatio",void 0),(0,r._)([(0,c.c)("adjustAspectRatio")],Y.prototype,"writeAdjustAspectRatio",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"bandIds",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compression",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compressionQuality",null),(0,r._)([(0,c.c)("compressionQuality")],Y.prototype,"writeCompressionQuality",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"compressionTolerance",null),(0,r._)([(0,c.c)("compressionTolerance")],Y.prototype,"writeCompressionTolerance",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"format",null),(0,r._)([(0,l.Cb)({type:String,json:{read:{reader:X.c.read},write:{writer:X.c.write}}})],Y.prototype,"interpolation",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"noData",null),(0,r._)([(0,l.Cb)({type:String,json:{read:{reader:X.k.read},write:{writer:X.k.write}}})],Y.prototype,"noDataInterpretation",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"pixelType",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"lercVersion",void 0),(0,r._)([(0,c.c)("lercVersion")],Y.prototype,"writeLercVersion",null),(0,r._)([(0,l.Cb)({type:Number})],Y.prototype,"version",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"mosaicRule",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Y.prototype,"renderingRule",null),Y=(0,r._)([(0,p.j)("esri.layers.mixins.ExportImageServiceParameters")],Y);var ee=i(1231),te=i(99514),ie=i(29876),re=i(5847),ne=i(48526),se=i(88281),oe=i(99815),ae=i(75993),le=i(80676),ue=i(67058),pe=i(72758),ce=i(51806),de=i(11282),me=i(82971);let he=class extends I.wq{constructor(){super(...arguments),this.north=null,this.up=null,this.spatialReference=null}};(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],he.prototype,"north",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],he.prototype,"up",void 0),(0,r._)([(0,l.Cb)({type:me.Z,json:{write:!0}})],he.prototype,"spatialReference",void 0),he=(0,r._)([(0,p.j)("esri.rest.support.ImageAngleResult")],he);const ye=he;var fe=i(74889);let ge=class extends I.wq{constructor(){super(...arguments),this.catalogItemVisibilities=null,this.catalogItems=null,this.location=null,this.name=null,this.objectId=null,this.processedValues=null,this.properties=null,this.value=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"catalogItemVisibilities",void 0),(0,r._)([(0,l.Cb)({type:fe.default,json:{write:!0}})],ge.prototype,"catalogItems",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],ge.prototype,"location",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"name",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"objectId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"processedValues",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"properties",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],ge.prototype,"value",void 0),ge=(0,r._)([(0,p.j)("esri.rest.support.ImageIdentifyResult")],ge);const be=ge;let Re=class extends I.wq{constructor(){super(...arguments),this.geometries=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],Re.prototype,"geometries",void 0),Re=(0,r._)([(0,p.j)("esri.rest.support.ImagePixelLocationResult")],Re);const ve=Re;let we=class extends I.wq{constructor(){super(...arguments),this.attributes=null,this.location=null,this.locationId=null,this.rasterId=null,this.resolution=null,this.pixelValue=null}};(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"attributes",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],we.prototype,"location",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"locationId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"rasterId",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"resolution",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],we.prototype,"pixelValue",void 0),we=(0,r._)([(0,p.j)("esri.rest.support.ImageSample")],we);const _e=we;let Ce=class extends I.wq{constructor(){super(...arguments),this.samples=null}};(0,r._)([(0,l.Cb)({type:[_e],json:{write:!0}})],Ce.prototype,"samples",void 0),Ce=(0,r._)([(0,p.j)("esri.rest.support.ImageSampleResult")],Ce);const Se=Ce;function xe(e){const t=e?.time;if(t&&(null!=t.start||null!=t.end)){const i=[];null!=t.start&&i.push(t.start),null==t.end||i.includes(t.end)||i.push(t.end),e.time=i.join(",")}}async function Ie(e,t,i){const r=(0,de.en)(e),n=t.geometry?[t.geometry]:[],o=await(0,ce.aX)(n),a=t.toJSON();xe(a);const l=o&&o[0];(0,s.pC)(l)&&(a.geometry=l.toJSON());const u=(0,de.cv)({...r.query,f:"json",...a});return(0,de.lA)(u,i)}async function Fe(e,t,i){const r=(0,de.en)(e),n=t.geometry?[t.geometry]:[];return(0,ce.aX)(n).then((e=>{const n=t.toJSON(),o=e&&e[0];(0,s.pC)(o)&&(n.geometry=JSON.stringify(o.toJSON()));const a=(0,de.cv)({...r.query,f:"json",...n}),l=(0,de.lA)(a,i);return(0,f.default)(r.path+"/identify",l)})).then((e=>be.fromJSON(e.data)))}function Te(e){const{imageCoordinateSystem:t}=e;if(t){const{id:e,referenceServiceName:i}=t;return null!=e?i?{icsid:e,icsns:i}:{icsid:e}:{ics:t}}return e.toJSON()}function Ne(e,t){const i=Te(e),{icsid:r,icsns:n,wkid:s}=i;return null!=r?null==n||t?.toLowerCase().includes("/"+n.toLowerCase()+"/")?`0:${r}`:JSON.stringify(i):s?s.toString():JSON.stringify(i)}i(80442),i(10158);var De,je=i(4967),Pe=(i(67900),i(8744),i(98732),i(6570)),Oe=(i(9361),i(65091)),Me=i(38913),Ve=(i(58901),i(45091),i(57444)),Ae=(i(40330),i(98326),i(56545),i(41818)),Je=i(5396),Ze=(i(75935),i(28141),i(26059)),Ee=i(36679);let qe=De=class extends I.wq{constructor(){super(...arguments),this.angleNames=null,this.point=null,this.spatialReference=null,this.rasterId=null}clone(){return new De((0,R.d9)({angleNames:this.angleNames,point:this.point,spatialReference:this.spatialReference,rasterId:this.rasterId}))}};(0,r._)([(0,l.Cb)({type:[String],json:{name:"angleName",write:!0}})],qe.prototype,"angleNames",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],qe.prototype,"point",void 0),(0,r._)([(0,l.Cb)({type:me.Z,json:{write:!0}})],qe.prototype,"spatialReference",void 0),(0,r._)([(0,l.Cb)({type:u.z8,json:{write:!0}})],qe.prototype,"rasterId",void 0),qe=De=(0,r._)([(0,p.j)("esri.rest.support.ImageAngleParameters")],qe);const ze=qe;var Le,He=i(92835),ke=i(33955);let Be=Le=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.mosaicRule=null,this.renderingRule=null,this.pixelSize=null,this.raster=void 0,this.timeExtent=null}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=e.toJSON())}clone(){return new Le((0,R.d9)({geometry:this.geometry,mosaicRule:this.mosaicRule,renderingRule:this.renderingRule,pixelSize:this.pixelSize,raster:this.raster,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({types:m.qM,json:{read:ke.im}})],Be.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],Be.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],Be.prototype,"mosaicRule",void 0),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],Be.prototype,"renderingRule",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],Be.prototype,"pixelSize",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Be.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{read:{source:"time"},write:{target:"time"}}})],Be.prototype,"timeExtent",void 0),Be=Le=(0,r._)([(0,p.j)("esri.rest.support.ImageHistogramParameters")],Be);const Ge=Be;var Qe;let Ue=Qe=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.renderingRules=null,this.pixelSize=null,this.returnGeometry=!0,this.returnCatalogItems=!0,this.returnPixelValues=!0,this.maxItemCount=null,this.timeExtent=null,this.raster=void 0,this.viewId=void 0,this.processAsMultidimensional=!1}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=JSON.stringify(e.toJSON()))}set mosaicRule(e){let t=e;t&&t.mosaicMethod&&(t=K.fromJSON({...t.toJSON(),mosaicMethod:t.mosaicMethod,mosaicOperation:t.mosaicOperation})),this._set("mosaicRule",t)}writeMosaicRule(e,t,i){null!=e&&(t[i]=JSON.stringify(e.toJSON()))}set renderingRule(e){let t=e;t&&t.rasterFunction&&(t=F.Z.fromJSON({...t.toJSON(),rasterFunction:t.rasterFunction,rasterFunctionArguments:t.rasterFunctionArguments})),this._set("renderingRule",t)}writeRenderingRule(e,t,i){null!=e&&(t[i]=JSON.stringify(e.toJSON())),e.rasterFunctionDefinition&&(t[i]=JSON.stringify(e.rasterFunctionDefinition))}writeRenderingRules(e,t,i){null!=e&&(t[i]=JSON.stringify(e.map((e=>e.rasterFunctionDefinition||e.toJSON()))))}writePixelSize(e,t,i){null!=e&&(t[i]=JSON.stringify(e))}writeTimeExtent(e,t,i){if(null!=e){const r=(0,s.pC)(e.start)?e.start.getTime():null,n=(0,s.pC)(e.end)?e.end.getTime():null;t[i]=null!=r?null!=n?`${r},${n}`:`${r}`:null}}clone(){return new Qe((0,R.d9)({geometry:this.geometry,mosaicRule:this.mosaicRule,renderingRule:this.renderingRule,pixelSize:this.pixelSize,returnGeometry:this.returnGeometry,returnCatalogItems:this.returnCatalogItems,returnPixelValues:this.returnPixelValues,maxItemCount:this.maxItemCount,processAsMultidimensional:this.processAsMultidimensional,raster:this.raster,viewId:this.viewId,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],Ue.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],Ue.prototype,"mosaicRule",null),(0,r._)([(0,c.c)("mosaicRule")],Ue.prototype,"writeMosaicRule",null),(0,r._)([(0,l.Cb)({type:F.Z,json:{write:!0}})],Ue.prototype,"renderingRule",null),(0,r._)([(0,c.c)("renderingRule")],Ue.prototype,"writeRenderingRule",null),(0,r._)([(0,l.Cb)({type:[F.Z],json:{write:!0}})],Ue.prototype,"renderingRules",void 0),(0,r._)([(0,c.c)("renderingRules")],Ue.prototype,"writeRenderingRules",null),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],Ue.prototype,"pixelSize",void 0),(0,r._)([(0,c.c)("pixelSize")],Ue.prototype,"writePixelSize",null),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnGeometry",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnCatalogItems",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"returnPixelValues",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],Ue.prototype,"maxItemCount",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{write:{target:"time"}}})],Ue.prototype,"timeExtent",void 0),(0,r._)([(0,c.c)("timeExtent")],Ue.prototype,"writeTimeExtent",null),(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({json:{write:!0}})],Ue.prototype,"viewId",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],Ue.prototype,"processAsMultidimensional",void 0),Ue=Qe=(0,r._)([(0,p.j)("esri.rest.support.ImageIdentifyParameters")],Ue);const We=Ue;var $e;let Ke=$e=class extends I.wq{constructor(){super(...arguments),this.geometries=null,this.rasterId=null}writeGeometry(e,t,i){t.geometries={geometryType:"esriGeometryPoint",geometries:e.map((e=>e.toJSON()))}}clone(){return new $e({geometries:this.geometries?.map((e=>e.clone()))??[],rasterId:this.rasterId})}};(0,r._)([(0,l.Cb)({type:[Q.Z],json:{write:!0}})],Ke.prototype,"geometries",void 0),(0,r._)([(0,c.c)("geometries")],Ke.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)({type:u.z8,json:{write:!0}})],Ke.prototype,"rasterId",void 0),Ke=$e=(0,r._)([(0,p.j)("esri.rest.support.ImagePixelLocationParameters")],Ke);const Xe=Ke;var Ye;let et=Ye=class extends I.wq{constructor(){super(...arguments),this.geometry=null,this.interpolation="nearest",this.mosaicRule=null,this.outFields=null,this.pixelSize=null,this.returnFirstValueOnly=!0,this.sampleDistance=null,this.sampleCount=null,this.sliceId=null,this.timeExtent=null}writeGeometry(e,t,i){null!=e&&(t.geometryType=(0,ke.Ji)(e),t[i]=e.toJSON())}set locations(e){if(e?.length){const t=new Oe.Z({spatialReference:e[0].spatialReference});t.points=e.map((e=>[e.x,e.y])),this._set("locations",e),this.geometry=t}}clone(){return new Ye((0,R.d9)({geometry:this.geometry,locations:this.locations,interpolation:this.interpolation,mosaicRule:this.mosaicRule,outFields:this.outFields,raster:this.raster,returnFirstValueOnly:this.returnFirstValueOnly,sampleDistance:this.sampleDistance,sampleCount:this.sampleCount,sliceId:this.sliceId,pixelSize:this.pixelSize,timeExtent:this.timeExtent}))}};(0,r._)([(0,l.Cb)({types:m.qM,json:{read:ke.im}})],et.prototype,"geometry",void 0),(0,r._)([(0,c.c)("geometry")],et.prototype,"writeGeometry",null),(0,r._)([(0,l.Cb)()],et.prototype,"locations",null),(0,r._)([(0,l.Cb)({type:String,json:{type:X.c.jsonValues,read:X.c.read,write:X.c.write}})],et.prototype,"interpolation",void 0),(0,r._)([(0,l.Cb)({type:K,json:{write:!0}})],et.prototype,"mosaicRule",void 0),(0,r._)([(0,l.Cb)({type:[String],json:{write:!0}})],et.prototype,"outFields",void 0),(0,r._)([(0,l.Cb)({type:Q.Z,json:{write:!0}})],et.prototype,"pixelSize",void 0),(0,r._)([(0,l.Cb)({type:String,json:{write:!0}})],et.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{write:!0}})],et.prototype,"returnFirstValueOnly",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sampleDistance",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sampleCount",void 0),(0,r._)([(0,l.Cb)({type:Number,json:{write:!0}})],et.prototype,"sliceId",void 0),(0,r._)([(0,l.Cb)({type:He.Z,json:{read:{source:"time"},write:{target:"time"}}})],et.prototype,"timeExtent",void 0),et=Ye=(0,r._)([(0,p.j)("esri.rest.support.ImageSampleParameters")],et);const tt=et;var it=i(23808);const rt=(0,b.w)()({U1:"u1",U2:"u2",U4:"u4",U8:"u8",S8:"s8",U16:"u16",S16:"s16",U32:"u32",S32:"s32",F32:"f32",F64:"f64",C64:"c64",C128:"c128",UNKNOWN:"unknown"}),nt=new Set(["png","png8","png24","png32","jpg","bmp","gif","jpgpng","lerc","tiff"]),st=(0,l.Eg)(u.q9,{min:0,max:255}),ot=e=>{let t=class extends e{constructor(){super(...arguments),this._functionRasterInfos={},this._rasterJobHandler={instance:null,refCount:0,connectionPromise:null},this._cachedRendererJson=null,this._serviceSupportsMosaicRule=null,this._rasterAttributeTableFieldPrefix="Raster.",this.adjustAspectRatio=null,this.bandIds=void 0,this.capabilities=null,this.compressionQuality=void 0,this.compressionTolerance=.01,this.copyright=null,this.defaultMosaicRule=null,this.definitionExpression=null,this.exportImageServiceParameters=null,this.rasterInfo=null,this.fields=null,this.fullExtent=null,this.hasMultidimensions=!1,this.imageMaxHeight=4100,this.imageMaxWidth=4100,this.interpolation=void 0,this.minScale=0,this.maxScale=0,this.multidimensionalSubset=null,this.noData=null,this.noDataInterpretation=void 0,this.objectIdField=null,this.geometryType="polygon",this.typeIdField=null,this.types=[],this.pixelFilter=null,this.raster=void 0,this.sourceType=null,this.viewId=void 0,this.symbolizer=null,this.rasterFunctionInfos=null,this.serviceDataType=null,this.spatialReference=null,this.pixelType=null,this.serviceRasterInfo=null,this.sourceJSON=null,this.url=null,this.version=void 0}initialize(){this._set("exportImageServiceParameters",new Y({layer:this}))}readServiceSupportsMosaicRule(e,t){return this._isMosaicRuleSupported(t)}get _rasterFunctionNamesIndex(){const e=new Map;return!this.rasterFunctionInfos||(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.length<1||(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.forEach((t=>{e.set(t.name.toLowerCase().replace(/ /gi,"_"),t.name)})),e}readBandIds(e,t){if(Array.isArray(e)&&e.length>0&&e.every((e=>"number"==typeof e)))return e}readCapabilities(e,t){return this._readCapabilities(t)}writeCompressionQuality(e,t,i){null!=e&&"lerc"!==this.format&&(t[i]=e)}writeCompressionTolerance(e,t,i){"lerc"===this.format&&null!=e&&(t[i]=e)}readDefaultMosaicRule(e,t){return this._serviceSupportsMosaicRule?K.fromJSON(t):null}get fieldsIndex(){return this.fields?new te.Z(this.fields):null}set format(e){e&&nt.has(e.toLowerCase())&&this._set("format",e.toLowerCase())}readFormat(e,t){return"esriImageServiceDataTypeVector-UV"===t.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===t.serviceDataType||null!=this.pixelFilter?"lerc":"jpgpng"}readMinScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}readMaxScale(e,t){return null!=t.minLOD&&null!=t.maxLOD?e:0}set mosaicRule(e){let t=e;t&&t.mosaicMethod&&(t=K.fromJSON({...t.toJSON(),mosaicMethod:t.mosaicMethod,mosaicOperation:t.mosaicOperation})),this._set("mosaicRule",t)}readMosaicRule(e,t){const i=e||t.mosaicRule;return i?K.fromJSON(i):this._isMosaicRuleSupported(t)?K.fromJSON(t):null}writeMosaicRule(e,t,i){let r=this.mosaicRule;const n=this.definitionExpression;r?n&&n!==r.where&&(r=r.clone(),r.where=n):n&&(r=new K({where:n})),this._isValidCustomizedMosaicRule(r)&&(t[i]=r.toJSON())}get multidimensionalInfo(){return(0,s.pC)(this.serviceRasterInfo)?this.serviceRasterInfo.multidimensionalInfo:null}writeNoData(e,t,i){null!=e&&"number"==typeof e&&(t[i]=st(e))}readObjectIdField(e,t){if(!e){const i=t.fields.filter((e=>"esriFieldTypeOID"===e.type||"oid"===e.type));e=i&&i[0]&&i[0].name}return e}get parsedUrl(){return(0,_.mN)(this.url)}readSourceType(e,t){return this._isMosaicDataset(t)?"mosaic-dataset":"raster-dataset"}set renderer(e){this.loaded&&(e=this._configRenderer(e)),this._set("renderer",e)}readRenderer(e,t,i){const r=t?.layerDefinition?.drawingInfo?.renderer,n=(0,y.ij)(r,i);return null==n?null:("vector-field"===n.type&&t.symbolTileSize&&!r.symbolTileSize&&(n.symbolTileSize=t.symbolTileSize),V(n)||v.Z.getLogger(this.declaredClass).warn("ArcGISImageService","Imagery layer doesn't support given renderer type."),n)}writeRenderer(e,t,i){t.layerDefinition=t.layerDefinition||{},t.layerDefinition.drawingInfo=t.layerDefinition.drawingInfo||{},t.layerDefinition.drawingInfo.renderer=e.toJSON(),"vector-field"===e.type&&(t.symbolTileSize=e.symbolTileSize)}get rasterFields(){const e=this._rasterAttributeTableFieldPrefix||"Raster.",t=new ee.Z({name:"Raster.ItemPixelValue",alias:"Item Pixel Value",domain:null,editable:!1,length:50,type:"string"}),i=new ee.Z({name:"Raster.ServicePixelValue",alias:"Service Pixel Value",domain:null,editable:!1,length:50,type:"string"}),r=new ee.Z({name:"Raster.ServicePixelValue.Raw",alias:"Raw Service Pixel Value",domain:null,editable:!1,length:50,type:"string"});let n=this.fields?(0,R.d9)(this.fields):[];n.push(i),this.capabilities?.operations.supportsQuery&&this.fields&&this.fields.length>0&&n.push(t),this.version>=10.4&&(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.some((e=>"none"===e.name.toLowerCase()))&&n.push(r),(0,s.pC)(this.rasterFunctionInfos)&&this.rasterFunctionInfos.filter((e=>"none"!==e.name.toLowerCase())).forEach((e=>{n.push(new ee.Z({name:"Raster.ServicePixelValue."+e.name,alias:e.name,domain:null,editable:!1,length:50,type:"string"}))})),this._isVectorDataSet()&&(n.push(new ee.Z({name:"Raster.Magnitude",alias:"Magnitude",domain:null,editable:!1,type:"double"})),n.push(new ee.Z({name:"Raster.Direction",alias:"Direction",domain:null,editable:!1,type:"double"})));const{attributeTable:o}=this.rasterInfo??{};if((0,s.pC)(o)){const t=o.fields.filter((e=>"esriFieldTypeOID"!==e.type&&"value"!==e.name.toLowerCase())).map((t=>{const i=(0,R.d9)(t);return i.name=e+t.name,i}));n=n.concat(t)}return n}set renderingRule(e){let t=e;t&&t.rasterFunction&&(t=F.Z.fromJSON({...t.toJSON(),rasterFunction:t.rasterFunction,rasterFunctionArguments:t.rasterFunctionArguments})),this._set("renderingRule",t)}readRenderingRule(e,t){const i=t.rasterFunctionInfos;return t.renderingRule||i&&i.length&&"None"!==i[0].name?this._isRFTJson(t.renderingRule)?F.Z.fromJSON({rasterFunctionDefinition:t.renderingRule}):F.Z.fromJSON(t.renderingRule||{rasterFunctionInfos:t.rasterFunctionInfos}):null}writeRenderingRule(e,t,i){const r=e.toJSON();r.rasterFunctionDefinition?t[i]=r.rasterFunctionDefinition:t[i]=r}readSpatialReference(e,t){const i=e||t.extent.spatialReference;return i?me.Z.fromJSON(i):null}readPixelType(e){return rt.fromJSON(e)||e}writePixelType(e,t,i){((0,s.Wi)(this.serviceRasterInfo)||this.pixelType!==this.serviceRasterInfo.pixelType)&&(t[i]=rt.toJSON(e))}readVersion(e,t){let i=t.currentVersion;return i||(i=t.hasOwnProperty("fields")||t.hasOwnProperty("timeInfo")?10:9.3),i}applyFilter(e){let t=e;return this.pixelFilter&&(t=this._clonePixelData(e),this.pixelFilter(t)),t}async applyRenderer(e,t){let i=e;const{renderer:r,symbolizer:n,pixelFilter:s,bandIds:o}=this;if(!this._isPicture()&&r&&n&&!s){const s=JSON.stringify(this._cachedRendererJson)!==JSON.stringify(r.toJSON()),a=this._rasterJobHandler.instance;if(a){s&&(n.bind(),await a.updateSymbolizer(n,t),this._cachedRendererJson=r.toJSON());const l=await a.symbolize({bandIds:o,...e},t);i={extent:e.extent,pixelBlock:l}}else i={extent:e.extent,pixelBlock:n.symbolize({bandIds:o,...e})}}return i}destroy(){this._shutdownJobHandler()}increaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount++}decreaseRasterJobHandlerUsage(){this._rasterJobHandler.refCount--,this._rasterJobHandler.refCount<=0&&this._shutdownJobHandler()}async computeAngles(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeAngles)throw new g.Z("imagery-layer:compute-angles","this operation is not supported on the input image service");return e=(0,u.TJ)(ze,e).clone(),async function(e,t,i){const r=t.toJSON();(0,s.pC)(r.angleName)&&(r.angleName=r.angleName.join(",")),(0,s.pC)(t.point)&&t.point.spatialReference?.imageCoordinateSystem&&(r.point.spatialReference=Te(t.point.spatialReference)),(0,s.pC)(t.spatialReference)&&t.spatialReference.imageCoordinateSystem&&(r.spatialReference=Ne(t.spatialReference));const n=(0,de.en)(e),o=(0,de.cv)({...n.query,f:"json",...r}),a=(0,de.lA)(o,i),{data:l}=await(0,f.default)(`${n.path}/computeAngles`,a);return l.spatialReference=l.spatialReference?null!=l.spatialReference.geodataXform?new me.Z({wkid:0,imageCoordinateSystem:l.spatialReference}):me.Z.fromJSON(l.spatialReference):null,"NaN"===l.north&&(l.north=null),"NaN"===l.up&&(l.up=null),new ye(l)}(this.url,e,this._getRequestOptions(t))}async computePixelSpaceLocations(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputePixelLocation)throw new g.Z("imagery-layer:compute-pixel-space-locations","this operation is not supported on the input image service");return e=(0,u.TJ)(Xe,e).clone(),async function(e,t,i){const r=t.toJSON(),{geometries:n}=t;if(n)for(let e=0;e<n.length;e++)n[e].spatialReference?.imageCoordinateSystem&&(r.geometries.geometries[e].spatialReference=Te(n[e].spatialReference));const s=(0,de.en)(e),o=(0,de.cv)({...s.query,f:"json",...r}),a=(0,de.lA)(o,i),{data:l}=await(0,f.default)(`${s.path}/computePixelLocation`,a);return ve.fromJSON(l)}(this.url,e,this._getRequestOptions(t))}async computeHistograms(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeHistograms)throw new g.Z("imagery-layer:compute-histograms","this operation is not supported on the input image service");e=(0,u.TJ)(Ge,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;return n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule&&(e.mosaicRule=r),i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=await Ie(e,t,i),n=(0,de.en)(e),{data:s}=await(0,f.default)(`${n.path}/computeHistograms`,r);return{histograms:s.histograms}}(this.url,e,this._getRequestOptions(t))}async computeStatisticsHistograms(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsComputeStatisticsHistograms)throw new g.Z("imagery-layer:compute-statistics-histograms","this operation is not supported on the input image service");e=(0,u.TJ)(Ge,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;return n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule&&(e.mosaicRule=r),i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=await Ie(e,t,i),n=(0,de.en)(e),{data:s}=await(0,f.default)(`${n.path}/computeStatisticsHistograms`,r),{statistics:o}=s;return o?.length&&o.forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:o,histograms:s.histograms}}(this.url,e,this._getRequestOptions(t))}getField(e){const{fieldsIndex:t}=this;return(0,s.pC)(t)?t.get(e):void 0}getFieldDomain(e,t){const i=this.getField(e);return i?i.domain:null}async fetchImage(e,t,i,r={}){if(null==e||null==t||null==i)throw new g.Z("imagery-layer:fetch-image","Insufficient parameters for requesting an image. A valid extent, width and height values are required.");if(this.renderer||this.symbolizer){const e=await this.generateRasterInfo(this.renderingRule,{signal:r.signal});e&&(this.rasterInfo=e)}const n=this.getExportImageServiceParameters(e,t,i,r.timeExtent);if(null==n){if(r.requestAsImageElement&&this._canRequestImageElement(this.format)){const e=document.createElement("canvas");return e.width=t,e.height=i,{imageOrCanvasElement:e}}const n=(this.bandIds?.length||this.rasterInfo?.bandCount)??0,s=t*i,o=this.rasterInfo?.pixelType??"unknown",a=[];for(let e=0;e<n;e++)a.push(re.Z.createEmptyBand(o,s));return{pixelData:{pixelBlock:new re.Z({width:t,height:i,pixels:a,mask:new Uint8Array(s),pixelType:o}),extent:e}}}const s={imageServiceParameters:n,imageProps:{extent:e,width:t,height:i,format:this.format},requestAsImageElement:r.requestAsImageElement&&!this.pixelFilter||!1,signal:r.signal};return this._requestArrayBuffer(s)}fetchKeyProperties(e){return(0,f.default)(i(this.parsedUrl)+"/keyProperties",{query:this._getQueryParams({renderingRule:this.version>=10.3?e?.renderingRule:null})}).then((e=>e.data))}fetchRasterAttributeTable(e){return this.version<10.1?Promise.reject(new g.Z("#fetchRasterAttributeTable()","Failed to get rasterAttributeTable")):(0,f.default)(i(this.parsedUrl)+"/rasterAttributeTable",{query:this._getQueryParams({renderingRule:this.version>=10.3?e?.renderingRule:null})}).then((e=>fe.default.fromJSON(e.data)))}getCatalogItemRasterInfo(e,t){const r={...t,query:this._getQueryParams()};return async function(e,t,i){const r=(0,de.en)(e),n=(0,de.cv)({...r?.query,f:"json"}),s=(0,de.lA)(n,i),o=`${r?.path}/${t}/info`,a=(0,f.default)(`${o}`,s),l=(0,f.default)(`${o}/keyProperties`,s),u=await Promise.allSettled([a,l]),p="fulfilled"===u[0].status?u[0].value.data:null,c="fulfilled"===u[1].status?u[1].value.data:null;let d=null;p.statistics?.length&&(d=p.statistics.map((e=>({min:e[0],max:e[1],avg:e[2],stddev:e[3]}))));const m=Pe.Z.fromJSON(p.extent),h=Math.ceil(m.width/p.pixelSizeX-.1),y=Math.ceil(m.height/p.pixelSizeY-.1),g=m.spatialReference,b=new Q.Z({x:p.pixelSizeX,y:p.pixelSizeY,spatialReference:g}),R=p.histograms?.length?p.histograms:null,v=new Ee.Z({origin:p.origin,blockWidth:p.blockWidth,blockHeight:p.blockHeight,firstPyramidLevel:p.firstPyramidLevel,maximumPyramidLevel:p.maxPyramidLevel});return new ne.Z({width:h,height:y,bandCount:p.bandCount,extent:m,spatialReference:g,pixelSize:b,pixelType:p.pixelType.toLowerCase(),statistics:d,histograms:R,keyProperties:c,storageInfo:v})}(i(this.parsedUrl),e,r)}async getCatalogItemICSInfo(e,t){const{data:r}=await(0,f.default)(i(this.parsedUrl)+"/"+e+"/info/ics",{query:this._getQueryParams(),...t}),n=r&&r.ics;if(!n)return;let s=null;try{s=(await(0,f.default)(i(this.parsedUrl)+"/"+e+"/info",{query:this._getQueryParams(),...t})).data.extent}catch{}if(!s||!s.spatialReference)return{ics:n,icsToPixelTransform:null,icsExtent:null,northDirection:null};const o=this.version>=10.7?(0,f.default)(i(this.parsedUrl)+"/"+e+"/info/icstopixel",{query:this._getQueryParams(),...t}).then((e=>e.data)).catch((()=>({}))):{},a=s.spatialReference,l={geometries:JSON.stringify({geometryType:"esriGeometryEnvelope",geometries:[s]}),inSR:a.wkid||JSON.stringify(a),outSR:"0:"+e},u=(0,f.default)(i(this.parsedUrl)+"/project",{query:this._getQueryParams(l),...t}).then((e=>e.data)).catch((()=>({}))),p=(s.xmin+s.xmax)/2,c=(s.ymax-s.ymin)/6,d=s.ymin+c,m=[];for(let e=0;e<5;e++)m.push({x:p,y:d+c*e});const h={geometries:JSON.stringify({geometryType:"esriGeometryPoint",geometries:m}),inSR:a.wkid||JSON.stringify(a),outSR:"0:"+e},y=(0,f.default)(i(this.parsedUrl)+"/project",{query:this._getQueryParams(h),...t}).then((e=>e.data)).catch((()=>({}))),g=await Promise.all([o,u,y]);let b=g[0].ipxf;if(null==b){const e=n.geodataXform?.xf_0;"topup"===e?.name?.toLowerCase()&&6===e?.coefficients?.length&&(b={affine:{name:"ics [sensor: Frame] to pixel (column, row) transformation",coefficients:e.coefficients,cellsizeRatio:0,type:"GeometricXform"}})}const R=Pe.Z.fromJSON(g[1]&&g[1].geometries&&g[1].geometries[0]);R&&(R.spatialReference=new me.Z({wkid:0,imageCoordinateSystem:n}));const v=g[2].geometries?g[2].geometries.filter((e=>null!=e&&null!=e.x&&null!=e.y&&"NaN"!==e.x&&"NaN"!==e.y)):[],w=v.length;if(w<3)return{ics:n,icsToPixelTransform:b,icsExtent:R,northDirection:null};let _=0,C=0,S=0,x=0;for(let e=0;e<w;e++)_+=v[e].x,C+=v[e].y,S+=v[e].x*v[e].x,x+=v[e].x*v[e].y;const I=(w*x-_*C)/(w*S-_*_);let F=0;const T=v[4].x>v[0].x,N=v[4].y>v[0].y;return I===1/0?F=N?90:270:0===I?F=T?0:180:I>0?F=T?180*Math.atan(I)/Math.PI:180*Math.atan(I)/Math.PI+180:I<0&&(F=N?180+180*Math.atan(I)/Math.PI:360+180*Math.atan(I)/Math.PI),{ics:n,icsToPixelTransform:b,icsExtent:R,northDirection:F}}async generateRasterInfo(e,t){if(this.serviceRasterInfo&&(!e||"none"===e.functionName?.toLowerCase()||this._isVectorFieldResampleFunction(e)))return this.serviceRasterInfo;const i=function(e){if(!e)return null;const t=JSON.stringify(e).match(/"rasterFunction":"(.*?")/gi)?.map((e=>e.replace('"rasterFunction":"',"").replace('"',"")));return t?t.join("/"):null}(e);if(!i)return null;if(this._functionRasterInfos[i])return this._functionRasterInfos[i];const r=this._generateRasterInfo(e,t);this._functionRasterInfos[i]=r;try{return await r}catch{return this._functionRasterInfos[i]=null,null}}getExportImageServiceParameters(e,t,r,n){const o=Ne((e=e.clone().shiftCentralMeridian()).spatialReference,i(this.parsedUrl));this.pixelType!==this.serviceRasterInfo?.pixelType&&(this.exportImageServiceParameters.pixelType=this.pixelType);const a=this.exportImageServiceParameters.toJSON(),{bandIds:l,noData:u}=a;let{renderingRule:p}=a;const c=this.renderingRule?.rasterFunctionDefinition,d=!this.renderer||"raster-stretch"===this.renderer.type;if(l?.length&&this._hasRenderingRule(this.renderingRule)&&!c&&d){const e={rasterFunction:"ExtractBand",rasterFunctionArguments:{BandIds:l}};if("Stretch"===p.rasterFunction)e.rasterFunctionArguments.Raster=p.rasterFunctionArguments.Raster,p.rasterFunctionArguments.Raster=e;else if("Colormap"===p.rasterFunction){const t=p.rasterFunctionArguments.Raster;"Stretch"===t?.rasterFunction?(e.rasterFunctionArguments.Raster=t.rasterFunctionArguments.Raster,t.rasterFunctionArguments.Raster=e):(e.rasterFunctionArguments.Raster=t,p.rasterFunctionArguments.Raster=e)}else e.rasterFunctionArguments.Raster=p,p=e;a.bandIds=void 0}else a.bandIds=l?.join(",");u instanceof Array&&u.length>0&&(a.noData=u.join(","));const m=this._serviceSupportsMosaicRule?this._combineMosaicRuleWithTimeExtent(this.exportImageServiceParameters.mosaicRule,n):null;a.mosaicRule=(0,s.pC)(m)?JSON.stringify(m):null;const{multidimensionalSubset:h}=this;if(h&&(0,s.pC)(m)&&m.multidimensionalDefinition&&(0,oe.nb)(m.multidimensionalDefinition,h))return null;a.renderingRule=this._getRenderingRuleString(F.Z.fromJSON(p));const y={};if(n){const{start:e,end:t}=n.toJSON();let i;if(e&&t&&e===t?(y.time=""+e,i=[e]):null==e&&null==t||(y.time=`${e??"null"},${t??"null"}`,i=null!=e&&null!=t?[e,t]:[e??t]),i&&h){const e=new x.Z({variableName:"",dimensionName:"StdTime",isSlice:!0,values:i});if((0,oe.nb)([e],h))return null}}return{bbox:e.xmin+","+e.ymin+","+e.xmax+","+e.ymax,bboxSR:o,imageSR:o,size:t+","+r,...a,...y}}async getSamples(e,t){if(!(await this._fetchCapabilities(t?.signal))?.operations.supportsGetSamples)throw new g.Z("imagery-layer:get-samples","getSamples operation is not supported on the input image service");e=(0,u.TJ)(tt,e).clone();const{raster:i}=this;return i&&null==e.raster&&(e.raster=i),async function(e,t,i){const r=t.toJSON();xe(r),r.outFields?.length&&(r.outFields=r.outFields.join(","));const n=(await(0,ce.aX)(t.geometry))?.[0];(0,s.pC)(n)&&(r.geometry=n.toJSON());const o=(0,de.en)(e),a=(0,de.cv)({...o.query,f:"json",...r}),l=(0,de.lA)(a,i),{data:u}=await(0,f.default)(`${o.path}/getSamples`,l),p=u?.samples?.map((e=>{const t="NaN"===e.value||""===e.value?null:e.value.split(" ").map((e=>Number(e)));return{...e,pixelValue:t}}));return Se.fromJSON({samples:p})}(this.url,e,this._getRequestOptions(t))}async identify(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsIdentify)throw new g.Z("imagery-layer:query-rasters","query operation is not supported on the input image service");e=(0,u.TJ)(We,e).clone();const{raster:i,mosaicRule:r,renderingRule:n}=this;if(n&&null==e.renderingRule&&(e.renderingRule=n),r&&null==e.mosaicRule){const t=this._combineMosaicRuleWithTimeExtent(r,e.timeExtent);e.mosaicRule=(0,s.Wg)(t)}return i&&null==e.raster&&(e.raster=i),Fe(this.url,e,this._getRequestOptions(t))}createQuery(){const e=new Ve.Z;return e.outFields=["*"],e.returnGeometry=!0,e.where=this.definitionExpression||"1=1",e}async queryRasters(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,je.e)(this.url,e,t)}async queryObjectIds(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,Je.G)(this.url,e,t)}async queryRasterCount(e,t){return({query:e,requestOptions:t}=await this._prepareForQuery(e,t)),(0,Ae.P)(this.url,e,t)}async queryVisibleRasters(e,t){if(!e)throw new g.Z("imagery-layer: query-visible-rasters","missing query parameter");await this.load();const{pixelSize:i,returnDomainValues:r,returnTopmostRaster:n,showNoDataRecords:o}=t||{pixelSize:null,returnDomainValues:!1,returnTopmostRaster:!1,showNoDataRecords:!1};let a=!1,l=null,u=null;const p="raster.servicepixelvalue",c=this._rasterFunctionNamesIndex;if((0,s.pC)(e.outFields)&&(a=e.outFields.some((e=>!e.toLowerCase().includes(p))),this.version>=10.4)){const t=e.outFields.filter((e=>e.toLowerCase().includes(p)&&e.length>p.length)).map((e=>{const t=e.slice(p.length+1);return[this._updateRenderingRulesFunctionName(t,c),t]}));l=t.map((e=>new F.Z({functionName:e[0]}))),u=t.map((e=>e[1]));const{renderingRule:i}=this;0===l.length?i?.functionName?(l.push(i),u.push(i.functionName)):l=null:i?.functionName&&!l.some((e=>e.functionName===i.functionName))&&(l.push(i),u.push(i.functionName))}const d=(0,s.Wi)(e.outSpatialReference)||e.outSpatialReference.equals(this.spatialReference),m=e.timeExtent||this.timeExtent,h=this._combineMosaicRuleWithTimeExtent(this.exportImageServiceParameters.mosaicRule,m),y=this._getQueryParams({geometry:e.geometry,timeExtent:m,mosaicRule:h,renderingRule:this.version<10.4?this.renderingRule:null,renderingRules:l,pixelSize:i,returnCatalogItems:a,returnGeometry:d,raster:this.raster,maxItemCount:n?1:null});delete y.f;const f=new We(y);try{await this.generateRasterInfo(this.renderingRule);const i=await Fe(this.url,f,{signal:t?.signal,query:{...this.customParameters}}),n=e.outFields,l=null!=i.value&&i.value.toLowerCase().includes("nodata");if(!a||d||!i?.catalogItems?.features.length||!o&&l)return this._processVisibleRastersResponse(i,{returnDomainValues:r,templateRRFunctionNames:u,showNoDataRecords:o,templateFields:n});const p=this.objectIdField||"ObjectId",c=i.catalogItems?.features??[],m=c.map((e=>e.attributes?.[p])),h=new Ve.Z({objectIds:m,returnGeometry:!0,outSpatialReference:e.outSpatialReference,outFields:[p]}),y=await this.queryRasters(h);return y?.features?.length&&y.features.forEach((t=>{c.forEach((i=>{i.attributes[p]===t.attributes[p]&&(i.geometry=new Me.Z(t.geometry),(0,s.pC)(e.outSpatialReference)&&(i.geometry.spatialReference=e.outSpatialReference))}))})),this._processVisibleRastersResponse(i,{returnDomainValues:r,templateRRFunctionNames:u,showNoDataRecords:o,templateFields:n})}catch{throw new g.Z("imagery-layer:query-visible-rasters","encountered error when querying visible rasters")}}async fetchVariableStatisticsHistograms(e,t){const r=(0,f.default)(i(this.parsedUrl)+"/statistics",{query:this._getQueryParams({variable:e}),signal:t}).then((e=>e.data?.statistics)),n=(0,f.default)(i(this.parsedUrl)+"/histograms",{query:this._getQueryParams({variable:e}),signal:t}).then((e=>e.data?.histograms)),s=await Promise.all([r,n]);return s[0]&&s[0].forEach((e=>{e.avg=e.mean,e.stddev=e.standardDeviation})),{statistics:s[0]||null,histograms:s[1]||null}}async createFlowMesh(e,t){const i=this._rasterJobHandler.instance;return i?i.createFlowMesh(e,t):(0,it.GE)(e.meshType,e.simulationSettings,e.flowData,(0,s.pC)(t.signal)?t.signal:(new AbortController).signal)}getMultidimensionalSubsetVariables(e){const t=e??this.multidimensionalInfo;return(0,oe.jj)(this.multidimensionalSubset,t)}async _fetchService(e){await this._fetchServiceInfo(e),this.rasterInfo||(this.rasterInfo=this.serviceRasterInfo);const t=this.sourceJSON,r=(0,s.pC)(this.serviceRasterInfo)?Promise.resolve(this.serviceRasterInfo):(0,Ze.g)(i(this.parsedUrl),t,{signal:e,query:this._getQueryParams()}).then((e=>(this._set("serviceRasterInfo",e),e))),n=this._hasRenderingRule(this.renderingRule)?this.generateRasterInfo(this.renderingRule,{signal:e}):null,o=this._getRasterFunctionInfos();return Promise.all([r,n,o]).then((e=>{e[1]?this._set("rasterInfo",e[1]):this._set("rasterInfo",e[0]),e[2]&&this._set("rasterFunctionInfos",e[2]),this.renderer&&!this._isSupportedRenderer(this.renderer)&&(this._set("renderer",null),v.Z.getLogger(this.declaredClass).warn("ArcGISImageService","Switching to the default renderer. Renderer applied is not valid for this Imagery Layer")),this._set("renderer",this._configRenderer(this.renderer)),this.addHandles([(0,w.YP)((()=>this.renderingRule),(e=>{(this.renderer||this.symbolizer||this.popupEnabled&&this.popupTemplate)&&this.generateRasterInfo(e).then((e=>{e&&(this.rasterInfo=e)}))}))]);const{serviceRasterInfo:t}=this;t&&(0,s.pC)(t.multidimensionalInfo)&&this._updateMultidimensionalDefinition(t)}))}_combineMosaicRuleWithTimeExtent(e,t){const i=this.timeInfo;if((0,s.Wi)(e)||(0,s.Wi)(this.multidimensionalInfo)||(0,s.Wi)(t)||(0,s.Wi)(i?.startField))return e;const{startField:r}=i,n=this.multidimensionalInfo.variables.some((e=>e.dimensions.some((e=>e.name===r))))?r:"StdTime";if(e=e.clone(),"mosaic-dataset"===this.sourceType)return e.multidimensionalDefinition=e.multidimensionalDefinition?.filter((e=>e.dimensionName!==n)),this._cleanupMultidimensionalDefinition(e);e.multidimensionalDefinition=e.multidimensionalDefinition||[];const o=e.multidimensionalDefinition.filter((e=>e.dimensionName===n)),a=(0,s.pC)(t.start)?t.start.getTime():null,l=(0,s.pC)(t.end)?t.end.getTime():null,u=null==a||null==l||a===l,p=u?[a||l]:[[a,l]],c=this.version>=10.8;if(o.length)o.forEach((e=>{e.dimensionName===n&&(c?(e.dimensionName=null,e.isSlice=!1,e.values=[]):(e.isSlice=u,e.values=p))}));else if(!c){const t=e.multidimensionalDefinition.filter((e=>null!=e.variableName&&null==e.dimensionName));t.length?t.forEach((e=>{e.dimensionName=n,e.isSlice=u,e.values=p})):e.multidimensionalDefinition.push(new x.Z({variableName:"",dimensionName:n,isSlice:u,values:p}))}return this._cleanupMultidimensionalDefinition(e)}_cleanupMultidimensionalDefinition(e){return(0,s.Wi)(e)?null:(e.multidimensionalDefinition&&(e.multidimensionalDefinition=e.multidimensionalDefinition.filter((e=>!(!e.variableName&&!e.dimensionName))),0===e.multidimensionalDefinition.length&&(e.multidimensionalDefinition=null)),"mosaic-dataset"!==this.sourceType&&null==e.multidimensionalDefinition?null:e)}async _prepareForQuery(e,t){if(!(await this._fetchCapabilities(t?.signal)).operations.supportsQuery)throw new g.Z("imagery-layer:query-rasters","query operation is not supported on the input image service");return e=(0,s.pC)(e)?(0,u.TJ)(Ve.Z,e):this.createQuery(),t=this._getRequestOptions(t),this.raster&&(t.query={...t.query,raster:this.raster}),{query:e,requestOptions:t}}async _initJobHandler(){if(null!=this._rasterJobHandler.connectionPromise)return this._rasterJobHandler.connectionPromise;const e=new se.Z;this._rasterJobHandler.connectionPromise=e.initialize().then((()=>{this._rasterJobHandler.instance=e}),(()=>{})),await this._rasterJobHandler.connectionPromise}_shutdownJobHandler(){this._rasterJobHandler.instance&&this._rasterJobHandler.instance.destroy(),this._rasterJobHandler.instance=null,this._rasterJobHandler.connectionPromise=null,this._rasterJobHandler.refCount=0,this._cachedRendererJson=null}_isSupportedRenderer(e){const{rasterInfo:t,renderingRule:i}=this;return"unique-value"===e.type&&this._hasRenderingRule(i)&&1===t?.bandCount&&["u8","s8"].includes(t.pixelType)||null!=t&&null!=e&&(0,ue.U0)(t).includes(e.type)}async _fetchCapabilities(e){return this.capabilities||await this._fetchServiceInfo(e),this.capabilities}async _fetchServiceInfo(e){let t=this.sourceJSON;if(!t){const{data:r,ssl:n}=await(0,f.default)(i(this.parsedUrl),{query:this._getQueryParams(),signal:e});t=r,this.sourceJSON=t,n&&(this.url=this.url.replace(/^http:/i,"https:"))}if(t.capabilities?.toLowerCase().split(",").map((e=>e.trim())).indexOf("tilesonly")>-1)throw new g.Z("imagery-layer:fetch-service-info","use ImageryTileLayer to open tiles-only image services");this.read(t,{origin:"service",url:this.parsedUrl})}_isMosaicDataset(e){return e.serviceSourceType?"esriImageServiceSourceTypeMosaicDataset"===e.serviceSourceType:e.fields?.length>0}_isMosaicRuleSupported(e){if(!e)return!1;const t=this._isMosaicDataset(e),i=e.currentVersion>=10.71&&e.hasMultidimensions&&!(e.fields?.length>1);return t||i}_isVectorFieldResampleFunction(e){if((0,s.Wi)(e))return!1;const{functionName:t,functionArguments:i}=e,r="resample"===t?.toLowerCase(),n=i?.ResampleType||i?.resampleType;return r&&(7===n||10===n)}_isPicture(){return!this.format||this.format.includes("jpg")||this.format.includes("png")}_configRenderer(e){if(!this._isPicture()&&!this.pixelFilter||this._isVectorDataSet()){if(!this.bandIds&&this.rasterInfo&&this.rasterInfo.bandCount>=3){const e=(0,ue.YD)(this.rasterInfo);!e||3===this.rasterInfo.bandCount&&0===e[0]&&1===e[1]&&2===e[2]||(this.bandIds=e)}e||(e=(0,ue.Ob)(this.rasterInfo,{bandIds:this.bandIds,variableName:this.renderingRule?null:this.mosaicRule?.multidimensionalDefinition?.[0].variableName}));const t=(0,ue.ol)(e.toJSON());this.symbolizer?(this.symbolizer.rendererJSON=t,this.symbolizer.rasterInfo=this.rasterInfo):this.symbolizer=new pe.Z({rendererJSON:t,rasterInfo:this.rasterInfo}),this.symbolizer.bind().success||(this.symbolizer=null)}return e}_clonePixelData(e){return null==e?e:{extent:e.extent&&e.extent.clone(),pixelBlock:(0,s.pC)(e.pixelBlock)?e.pixelBlock.clone():null}}_getQueryParams(e){e&&(0,s.pC)(e.renderingRule)&&"string"!=typeof e.renderingRule&&(e.renderingRule=this._getRenderingRuleString(e.renderingRule));const{raster:t,viewId:i}=this;return{raster:t,viewId:i,f:"json",...e,...this.customParameters}}_getRequestOptions(e){return{...e,query:{...e?.query,...this.customParameters}}}_decodePixelBlock(e,t,i){return this._rasterJobHandler.instance?this._rasterJobHandler.instance.decode({data:e,options:t}):(0,ae.J)(e,t,i)}async _getRasterFunctionInfos(e){const t=this.sourceJSON.rasterFunctionInfos;return this.loaded?t:t&&this.version>=10.3?1===t.length&&"none"===t[0].name.toLowerCase()?t:(await(0,f.default)(i(this.parsedUrl)+"/rasterFunctionInfos",{query:this._getQueryParams(),signal:e})).data?.rasterFunctionInfos:null}_canRequestImageElement(e){return!this.pixelFilter&&(!e||e.includes("png"))}async _requestArrayBuffer(e){const{imageProps:t,requestAsImageElement:r,signal:n}=e;if(r&&this._canRequestImageElement(t.format))return{imageOrCanvasElement:(await(0,f.default)(i(this.parsedUrl)+"/exportImage",{responseType:"image",query:this._getQueryParams({f:"image",...this.refreshParameters,...e.imageServiceParameters}),signal:n})).data,params:t};const s=this._initJobHandler(),o=(0,f.default)(i(this.parsedUrl)+"/exportImage",{responseType:"array-buffer",query:this._getQueryParams({f:"image",...e.imageServiceParameters}),signal:n}),a=(await Promise.all([o,s]))[0].data,l=t.format||"jpgpng";let u=l;if("bsq"!==u&&"bip"!==u&&(u=(0,ae.y)(a)),!u)throw new g.Z("imagery-layer:fetch-image","unsupported format signature "+String.fromCharCode.apply(null,new Uint8Array(a)));const p={signal:n},c="gif"===l||"bmp"===l||l.includes("png")&&("png"===u||"jpg"===u)?(0,ae.J)(a,{useCanvas:!0,...t},p):this._decodePixelBlock(a,{width:t.width,height:t.height,planes:null,pixelType:null,noDataValue:null,format:l},p);return{pixelData:{pixelBlock:await c,extent:t.extent},params:t}}_generateRasterInfo(e,t){const r={...t,query:this._getQueryParams()};return(0,Ze.N)(i(this.parsedUrl),e,r)}_isValidCustomizedMosaicRule(e){return e&&JSON.stringify(e.toJSON())!==JSON.stringify(this.defaultMosaicRule?.toJSON())}_updateMultidimensionalDefinition(e){if(this._isValidCustomizedMosaicRule(this.mosaicRule))return;const t=(0,oe.Tj)(e,{multidimensionalSubset:this.multidimensionalSubset});if((0,s.pC)(t)&&t.length>0){this.mosaicRule=this.mosaicRule||new K;const e=this.mosaicRule.multidimensionalDefinition;!this.sourceJSON.defaultVariableName&&this.renderingRule&&"none"!==this.renderingRule.functionName?.toLowerCase()&&t.forEach((e=>e.variableName="")),(!e||e&&e.length<=0)&&(this.mosaicRule.multidimensionalDefinition=t)}}_processVisibleRastersResponse(e,t){t=t||{};const i=e.value,{templateRRFunctionNames:r,showNoDataRecords:n,returnDomainValues:o,templateFields:a}=t,l=e.processedValues;let u=e.catalogItems&&e.catalogItems.features,p=e.properties&&e.properties.Values&&e.properties.Values.map((e=>e.replace(/ /gi,", ")))||[];const c=this.objectIdField||"ObjectId",d="string"==typeof i&&i.toLowerCase().includes("nodata"),m=[];if(i&&!u&&!d){const e={};e[c]=0,p=[i],u=[new h.Z(this.fullExtent,null,e)]}if(!u)return[];let y,f,g;this._updateResponseFieldNames(u,a),d&&!n&&(u=[]);for(let e=0;e<u.length;e++){if(y=u[e],null!=i){if(f=p[e],g=this.renderingRule&&l&&l.length>0&&r&&r.length>0&&r.includes(this.renderingRule.functionName)?l[r.indexOf(this.renderingRule.functionName)]:i,"nodata"===f.toLowerCase()&&!n)continue;const t="Raster.ItemPixelValue",o="Raster.ServicePixelValue";y.attributes[t]=f,y.attributes[o]=g,this._updateFeatureWithMagDirValues(y,f);const a=this.fields&&this.fields.length>0;let u=this.renderingRule&&(0,s.pC)(this.serviceRasterInfo?.attributeTable)?a?f:i:g;this.renderingRule||(u=a?f:i),this._updateFeatureWithRasterAttributeTableValues(y,u)}if(y.sourceLayer=y.layer=this,o&&this._updateFeatureWithDomainValues(y),r&&l&&r.length===l.length)for(let e=0;e<r.length;e++){const t="Raster.ServicePixelValue."+r[e];y.attributes[t]=l[e]}m.push(u[e])}return m}_updateFeatureWithRasterAttributeTableValues(e,t){const i=this.rasterInfo&&this.rasterInfo.attributeTable||this.serviceRasterInfo?.attributeTable;if((0,s.Wi)(i))return;const{features:r,fields:n}=i,o=n.map((e=>e.name)).filter((e=>"value"===e.toLowerCase())),a=o&&o[0];if(!a)return;const l=r.filter((e=>e.attributes[a]===(null!=t?parseInt(t,10):null)));l&&l[0]&&n.forEach((t=>{const i=this._rasterAttributeTableFieldPrefix+t.name;e.attributes[i]=l[0].attributes[t.name]}))}_updateFeatureWithMagDirValues(e,t){if(!this._isVectorDataSet())return;const i=t.split(/,\s*/).map((e=>parseFloat(e))),r=i.map((e=>[e])),n=i.map((e=>({minValue:e,maxValue:e,noDataValue:null}))),s=new re.Z({height:1,width:1,pixelType:"f32",pixels:r,statistics:n});null!=this.pixelFilter&&this.pixelFilter({pixelBlock:s,extent:new Pe.Z(0,0,0,0,this.spatialReference)});const o="esriImageServiceDataTypeVector-MagDir"===this.serviceDataType?[s.pixels[0][0],s.pixels[1][0]]:(0,le.Tg)([s.pixels[0][0],s.pixels[1][0]]);e.attributes["Raster.Magnitude"]=o[0],e.attributes["Raster.Direction"]=o[1]}_updateFeatureWithDomainValues(e){const t=this.fields&&this.fields.filter((e=>e.domain&&"coded-value"===e.domain.type));null!=t&&t.forEach((t=>{const i=e.attributes[t.name];if(null!=i){const r=t.domain.codedValues.find((e=>e.code===i));r&&(e.attributes[t.name]=r.name)}}))}_updateResponseFieldNames(e,t){if(!t||t.length<1)return;const i=this.fieldsIndex;(0,s.Wi)(i)||e.forEach((e=>{if(e&&e.attributes)for(const r of t){const t=i.get(r)?.name;t&&t!==r&&(e.attributes[r]=e.attributes[t],delete e.attributes[t])}}))}_getRenderingRuleString(e){if(this._hasRenderingRule(e)){let t=e.toJSON();return t=t.rasterFunctionDefinition??t,(t.thumbnail||t.thumbnailEx)&&(t.thumbnail=t.thumbnailEx=null),JSON.stringify(t)}return null}_hasRenderingRule(e){return null!=e&&null!=e.functionName&&"none"!==e.functionName.toLowerCase()}_updateRenderingRulesFunctionName(e,t){if(!e||e.length<1)return;if("Raw"===e)return e.replace("Raw","None");const i=e.toLowerCase().replace(/ /gi,"_");return t.has(i)?t.get(i):e}_isRFTJson(e){return e&&e.name&&e.arguments&&e.function&&e.hasOwnProperty("functionType")}_isVectorDataSet(){return"esriImageServiceDataTypeVector-UV"===this.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===this.serviceDataType}_readCapabilities(e){const t=e.capabilities?e.capabilities.toLowerCase().split(",").map((e=>e.trim())):["image","catalog"],{currentVersion:i,advancedQueryCapabilities:r,maxRecordCount:n}=e,s=t.includes("image"),o="esriImageServiceDataTypeElevation"===e.serviceDataType,a=!!(e.spatialReference||e.extent&&e.extent.spatialReference),l=t.includes("edit");return{data:{supportsAttachment:!1},operations:{supportsComputeHistograms:s,supportsExportImage:s,supportsIdentify:s,supportsMeasure:t.includes("mensuration")&&a,supportsDownload:t.includes("download"),supportsQuery:t.includes("catalog")&&e.fields&&e.fields.length>0,supportsGetSamples:i>=10.2&&s,supportsProject:i>=10.3&&s,supportsComputeStatisticsHistograms:i>=10.4&&s,supportsQueryBoundary:i>=10.6&&s,supportsCalculateVolume:i>=10.7&&o,supportsComputePixelLocation:i>=10.7&&t.includes("catalog"),supportsComputeAngles:i>=10.91,supportsAdd:l,supportsDelete:l,supportsEditing:l,supportsUpdate:l,supportsCalculate:!1,supportsTruncate:!1,supportsValidateSql:!1,supportsChangeTracking:!1,supportsQueryAttachments:!1,supportsResizeAttachments:!1,supportsSync:!1,supportsExceedsLimitStatistics:!1,supportsQueryAnalytics:!1,supportsQueryTopFeatures:!1},query:{maxRecordCount:n,maxRecordCountFactor:void 0,supportsStatistics:!!r?.supportsStatistics,supportsOrderBy:!!r?.supportsOrderBy,supportsDistinct:!!r?.supportsDistinct,supportsPagination:!!r?.supportsPagination,supportsStandardizedQueriesOnly:!!r?.useStandardizedQueries,supportsPercentileStatistics:!!r?.supportsPercentileStatistics,supportsCentroid:!!r?.supportsReturningGeometryCentroid,supportsDistance:!!r?.supportsQueryWithDistance,supportsExtent:!!r?.supportsReturningQueryExtent,supportsGeometryProperties:!!r?.supportsReturningGeometryProperties,supportsHavingClause:!!r?.supportsHavingClause,supportsQuantization:!1,supportsQuantizationEditMode:!1,supportsQueryGeometry:!1,supportsResultType:!1,supportsMaxRecordCountFactor:!1,supportsSqlExpression:!1,supportsTopFeaturesQuery:!1,supportsQueryByOthers:!1,supportsHistoricMoment:!1,supportsFormatPBF:!1,supportsDisjointSpatialRelationship:!1,supportsCacheHint:!1,supportsSpatialAggregationStatistics:!1,supportedSpatialAggregationStatistics:{envelope:!1,centroid:!1,convexHull:!1},supportsDefaultSpatialReference:!!r?.supportsDefaultSR,supportsCompactGeometry:!1,standardMaxRecordCount:void 0,tileMaxRecordCount:void 0}}}};function i(e){return e?.path??""}return(0,r._)([(0,l.Cb)()],t.prototype,"_functionRasterInfos",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"_rasterJobHandler",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"_cachedRendererJson",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"_serviceSupportsMosaicRule",void 0),(0,r._)([(0,C.r)("_serviceSupportsMosaicRule",["currentVersion","fields"])],t.prototype,"readServiceSupportsMosaicRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"_rasterAttributeTableFieldPrefix",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"_rasterFunctionNamesIndex",null),(0,r._)([(0,l.Cb)()],t.prototype,"adjustAspectRatio",void 0),(0,r._)([(0,l.Cb)({type:[u.z8],json:{write:!0}})],t.prototype,"bandIds",void 0),(0,r._)([(0,C.r)("bandIds")],t.prototype,"readBandIds",null),(0,r._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],t.prototype,"capabilities",void 0),(0,r._)([(0,C.r)("service","capabilities",["capabilities","currentVersion","serviceDataType"])],t.prototype,"readCapabilities",null),(0,r._)([(0,l.Cb)({type:Number})],t.prototype,"compressionQuality",void 0),(0,r._)([(0,c.c)("compressionQuality")],t.prototype,"writeCompressionQuality",null),(0,r._)([(0,l.Cb)({type:Number})],t.prototype,"compressionTolerance",void 0),(0,r._)([(0,c.c)("compressionTolerance")],t.prototype,"writeCompressionTolerance",null),(0,r._)([(0,l.Cb)({json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,dependsOn:["_serviceSupportsMosaicRule"]})],t.prototype,"defaultMosaicRule",void 0),(0,r._)([(0,C.r)("defaultMosaicRule",["defaultMosaicMethod"])],t.prototype,"readDefaultMosaicRule",null),(0,r._)([(0,l.Cb)({type:String,json:{name:"layerDefinition.definitionExpression",write:{enabled:!0,allowNull:!0}}})],t.prototype,"definitionExpression",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,constructOnly:!0})],t.prototype,"exportImageServiceParameters",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"rasterInfo",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:[ee.Z]})],t.prototype,"fields",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"fieldsIndex",null),(0,r._)([(0,l.Cb)({type:["png","png8","png24","png32","jpg","bmp","gif","jpgpng","lerc","tiff"],json:{write:!0}})],t.prototype,"format",null),(0,r._)([(0,C.r)("service","format",["serviceDataType"])],t.prototype,"readFormat",null),(0,r._)([(0,l.Cb)({type:Pe.Z})],t.prototype,"fullExtent",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"hasMultidimensions",void 0),(0,r._)([(0,l.Cb)({json:{read:{source:"maxImageHeight"}}})],t.prototype,"imageMaxHeight",void 0),(0,r._)([(0,l.Cb)({json:{read:{source:"maxImageWidth"}}})],t.prototype,"imageMaxWidth",void 0),(0,r._)([(0,l.Cb)({type:String,json:{type:X.c.jsonValues,read:X.c.read,write:X.c.write}})],t.prototype,"interpolation",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"minScale",void 0),(0,r._)([(0,C.r)("service","minScale")],t.prototype,"readMinScale",null),(0,r._)([(0,l.Cb)()],t.prototype,"maxScale",void 0),(0,r._)([(0,C.r)("service","maxScale")],t.prototype,"readMaxScale",null),(0,r._)([(0,l.Cb)({type:K})],t.prototype,"mosaicRule",null),(0,r._)([(0,C.r)("mosaicRule",["mosaicRule","defaultMosaicMethod"])],t.prototype,"readMosaicRule",null),(0,r._)([(0,c.c)("mosaicRule")],t.prototype,"writeMosaicRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"multidimensionalInfo",null),(0,r._)([(0,l.Cb)({type:ie.Z,json:{write:!0}})],t.prototype,"multidimensionalSubset",void 0),(0,r._)([(0,l.Cb)({json:{type:u.z8}})],t.prototype,"noData",void 0),(0,r._)([(0,c.c)("noData")],t.prototype,"writeNoData",null),(0,r._)([(0,l.Cb)({type:String,json:{type:X.k.jsonValues,read:X.k.read,write:X.k.write}})],t.prototype,"noDataInterpretation",void 0),(0,r._)([(0,l.Cb)({type:String,readOnly:!0,json:{read:{source:["fields"]}}})],t.prototype,"objectIdField",void 0),(0,r._)([(0,C.r)("objectIdField")],t.prototype,"readObjectIdField",null),(0,r._)([(0,l.Cb)({})],t.prototype,"geometryType",void 0),(0,r._)([(0,l.Cb)({})],t.prototype,"typeIdField",void 0),(0,r._)([(0,l.Cb)({})],t.prototype,"types",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"parsedUrl",null),(0,r._)([(0,l.Cb)({type:Function})],t.prototype,"pixelFilter",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"raster",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"sourceType",void 0),(0,r._)([(0,C.r)("sourceType",["serviceSourceType","fields"])],t.prototype,"readSourceType",null),(0,r._)([(0,l.Cb)()],t.prototype,"viewId",void 0),(0,r._)([(0,l.Cb)({types:y.dr,json:{name:"layerDefinition.drawingInfo.renderer",origins:{"web-scene":{types:y.FK,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type&&"flow"!==e.type})}}}}})],t.prototype,"renderer",null),(0,r._)([(0,C.r)("renderer")],t.prototype,"readRenderer",null),(0,r._)([(0,c.c)("renderer")],t.prototype,"writeRenderer",null),(0,r._)([(0,l.Cb)()],t.prototype,"symbolizer",void 0),(0,r._)([(0,l.Cb)(S.Oh)],t.prototype,"opacity",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"rasterFields",null),(0,r._)([(0,l.Cb)({constructOnly:!0})],t.prototype,"rasterFunctionInfos",void 0),(0,r._)([(0,l.Cb)({type:F.Z})],t.prototype,"renderingRule",null),(0,r._)([(0,C.r)("renderingRule",["renderingRule","rasterFunctionInfos"])],t.prototype,"readRenderingRule",null),(0,r._)([(0,c.c)("renderingRule")],t.prototype,"writeRenderingRule",null),(0,r._)([(0,l.Cb)()],t.prototype,"serviceDataType",void 0),(0,r._)([(0,l.Cb)({readOnly:!0,type:me.Z})],t.prototype,"spatialReference",void 0),(0,r._)([(0,C.r)("spatialReference",["spatialReference","extent"])],t.prototype,"readSpatialReference",null),(0,r._)([(0,l.Cb)({json:{type:rt.jsonValues}})],t.prototype,"pixelType",void 0),(0,r._)([(0,C.r)("pixelType")],t.prototype,"readPixelType",null),(0,r._)([(0,c.c)("pixelType")],t.prototype,"writePixelType",null),(0,r._)([(0,l.Cb)({constructOnly:!0,type:ne.Z})],t.prototype,"serviceRasterInfo",void 0),(0,r._)([(0,l.Cb)()],t.prototype,"sourceJSON",void 0),(0,r._)([(0,l.Cb)(S.HQ)],t.prototype,"url",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],t.prototype,"version",void 0),(0,r._)([(0,C.r)("version",["currentVersion","fields","timeInfo"])],t.prototype,"readVersion",null),t=(0,r._)([(0,p.j)("esri.layers.mixins.ArcGISImageService")],t),t};var at=i(17287),lt=i(71612),ut=i(17017),pt=i(38009),ct=i(16859),dt=i(34760),mt=i(72965),ht=i(28294),yt=i(60199),ft=i(32163);let gt=class extends((0,lt.h)((0,ht.n)((0,mt.M)((0,pt.q)((0,ct.I)(ot((0,dt.Q)((0,ut.N)((0,at.Y)((0,o.R)(d.Z))))))))))){constructor(...e){super(...e),this.legendEnabled=!0,this.isReference=null,this.operationalLayerType="ArcGISImageServiceLayer",this.popupEnabled=!0,this.popupTemplate=null,this.type="imagery"}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}load(e){const t=(0,s.pC)(e)?e.signal:null;return this.addResolvingPromise(this.loadFromPortal({supportedTypes:["Image Service"]},e).catch(a.r9).then((()=>this._fetchService(t)))),Promise.resolve(this)}writeOperationalLayerType(e,t,i){const r="vector-field"===this.renderer?.type;t[i]=r?"ArcGISImageServiceVectorLayer":"ArcGISImageServiceLayer"}get defaultPopupTemplate(){return this.createPopupTemplate()}createPopupTemplate(e){const t=this.rasterFields,i=this.title,r=new Set;let n=!1,s=!1;this.capabilities&&(n=this.capabilities.operations.supportsQuery&&this.fields&&this.fields.length>0,s="esriImageServiceDataTypeVector-UV"===this.serviceDataType||"esriImageServiceDataTypeVector-MagDir"===this.serviceDataType);const o=new Set;n&&o.add("raster.itempixelvalue");for(const e of t){const t=e.name.toLowerCase();o.has(t)||t.includes("raster.servicepixelvalue.")||r.add(e.name)}return s&&r.add("raster.magnitude").add("raster.direction"),(0,ft.eZ)({fields:t,title:i},{...e,visibleFieldNames:r})}queryFeatures(e,t){return this.queryRasters(e,t).then((e=>{if(e?.features)for(const t of e.features)t.layer=t.sourceLayer=this;return e}))}queryFeatureCount(e,t){return this.queryRasterCount(e,t)}redraw(){this.emit("redraw")}serviceSupportsSpatialReference(e){return(0,yt.D)(this,e)}};(0,r._)([(0,l.Cb)(S.rn)],gt.prototype,"legendEnabled",void 0),(0,r._)([(0,l.Cb)({type:["show","hide"]})],gt.prototype,"listMode",void 0),(0,r._)([(0,l.Cb)({type:Boolean,json:{read:!1,write:{enabled:!0,overridePolicy:()=>({enabled:!1})}}})],gt.prototype,"isReference",void 0),(0,r._)([(0,l.Cb)({type:["ArcGISImageServiceLayer"],json:{origins:{"web-map":{type:["ArcGISImageServiceLayer","ArcGISImageServiceVectorLayer"],read:!1,write:{target:"layerType",ignoreOrigin:!0}}}}})],gt.prototype,"operationalLayerType",void 0),(0,r._)([(0,c.c)("web-map","operationalLayerType")],gt.prototype,"writeOperationalLayerType",null),(0,r._)([(0,l.Cb)(S.C_)],gt.prototype,"popupEnabled",void 0),(0,r._)([(0,l.Cb)({type:n.Z,json:{read:{source:"popupInfo"},write:{target:"popupInfo"}}})],gt.prototype,"popupTemplate",void 0),(0,r._)([(0,l.Cb)({readOnly:!0})],gt.prototype,"defaultPopupTemplate",null),(0,r._)([(0,l.Cb)({readOnly:!0,json:{read:!1}})],gt.prototype,"type",void 0),gt=(0,r._)([(0,p.j)("esri.layers.ImageryLayer")],gt);const bt=gt},17287:(e,t,i)=>{i.d(t,{Y:()=>u});var r=i(43697),n=i(92604),s=i(70586),o=i(5600),a=(i(67676),i(75215),i(52011)),l=i(66677);const u=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,l.Qc)(this.url);if((0,s.pC)(e)&&e.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,l.Nm)(e,n.Z.getLogger(this.declaredClass)))}};return(0,r._)([(0,o.Cb)()],t.prototype,"title",null),(0,r._)([(0,o.Cb)({type:String})],t.prototype,"url",null),t=(0,r._)([(0,a.j)("esri.layers.mixins.ArcGISService")],t),t}},60199:(e,t,i)=>{i.d(t,{D:()=>s});var r=i(66677);const n=[];function s(e,t){if((0,r.M8)(e.url??""))return!0;const{wkid:i}=t;for(const t of n){if((e.version??0)>=t[0])return!0;if("function"==typeof t[1]&&(t[1]=t[1]()),t[1].has(i))return!1}return!0}n.push([10.91,()=>{const e=new Set([9709,9716,9741,9761,9766]);for(let t=9712;t<=9713;t++)e.add(t);for(let t=9748;t<=9749;t++)e.add(t);for(let t=20904;t<=20932;t++)e.add(t);for(let t=21004;t<=21032;t++)e.add(t);for(let t=21207;t<=21264;t++)e.add(t);for(let t=21307;t<=21364;t++)e.add(t);for(let t=102759;t<=102760;t++)e.add(t);for(let t=102901;t<=102955;t++)e.add(t);return e}]),n.push([10.9,()=>{const e=new Set([9300,9354,9364,9367,9373,9377,9387,9456,9473,9498,9678,9680,29874,103599,103872,104028]);for(let t=9356;t<=9360;t++)e.add(t);for(let t=9404;t<=9407;t++)e.add(t);for(let t=9476;t<=9482;t++)e.add(t);for(let t=9487;t<=9494;t++)e.add(t);for(let t=9697;t<=9699;t++)e.add(t);return e}]),n.push([10.81,()=>{const e=new Set([9265,9333,103598,103699]);for(let t=9248;t<=9254;t++)e.add(t);for(let t=9271;t<=9273;t++)e.add(t);for(let t=9284;t<=9285;t++)e.add(t);for(let t=21453;t<=21463;t++)e.add(t);return e}]),n.push([10.8,()=>{const e=new Set([8088,8395,8428,8433,8531,8687,8692,8694,8699,8900,9003,9006,9009,9012,9017,9191]);for(let t=8035;t<=8036;t++)e.add(t);for(let t=8455;t<=8456;t++)e.add(t);for(let t=8518;t<=8529;t++)e.add(t);for(let t=8533;t<=8536;t++)e.add(t);for(let t=8538;t<=8540;t++)e.add(t);for(let t=8677;t<=8679;t++)e.add(t);for(let t=8902;t<=8903;t++)e.add(t);for(let t=8907;t<=8910;t++)e.add(t);for(let t=8949;t<=8951;t++)e.add(t);for(let t=8972;t<=8987;t++)e.add(t);for(let t=9039;t<=9040;t++)e.add(t);for(let t=9068;t<=9069;t++)e.add(t);for(let t=9140;t<=9141;t++)e.add(t);for(let t=9148;t<=9150;t++)e.add(t);for(let t=9153;t<=9159;t++)e.add(t);for(let t=9205;t<=9218;t++)e.add(t);for(let t=9221;t<=9222;t++)e.add(t);for(let t=54098;t<=54101;t++)e.add(t);return e}]),n.push([10.71,()=>{const e=new Set([6316]);for(let t=8351;t<=8353;t++)e.add(t);for(let t=9294;t<=9297;t++)e.add(t);for(let t=103586;t<=103594;t++)e.add(t);for(let t=103696;t<=103698;t++)e.add(t);return e}]),n.push([10.7,()=>{const e=new Set([8387,8391,8427,8545,8682,8685,8818,31370,104022,104024,104975]);for(let t=8065;t<=8068;t++)e.add(t);for(let t=8082;t<=8083;t++)e.add(t);for(let t=8379;t<=8385;t++)e.add(t);for(let t=8836;t<=8840;t++)e.add(t);for(let t=8857;t<=8860;t++)e.add(t);for(let t=53035;t<=53037;t++)e.add(t);for(let t=54090;t<=54091;t++)e.add(t);for(let t=102498;t<=102499;t++)e.add(t);return e}]),n.push([10.61,()=>new Set([102497])]),n.push([10.6,()=>{const e=new Set([7803,7805,7887,8086,8232,8237,8240,8246,8249,8252,8255,9019,9391]);for(let t=7755;t<=7787;t++)e.add(t);for(let t=7791;t<=7795;t++)e.add(t);for(let t=7799;t<=7801;t++)e.add(t);for(let t=7825;t<=7831;t++)e.add(t);for(let t=7877;t<=7878;t++)e.add(t);for(let t=7882;t<=7883;t++)e.add(t);for(let t=7991;t<=7992;t++)e.add(t);for(let t=8042;t<=8043;t++)e.add(t);for(let t=8058;t<=8059;t++)e.add(t);for(let t=8311;t<=8348;t++)e.add(t);for(let t=9060;t<=9067;t++)e.add(t);for(let t=102562;t<=102568;t++)e.add(t);for(let t=102799;t<=102900;t++)e.add(t);return e}]),n.push([10.51,()=>{const e=new Set([7683,7881,7886,7899,8888,9e3]);for(let t=8013;t<=8032;t++)e.add(t);for(let t=9053;t<=9057;t++)e.add(t);for(let t=104017;t<=104018;t++)e.add(t);for(let t=104971;t<=104974;t++)e.add(t);return e}]),n.push([10.5,()=>{const e=new Set([6962,7035,7037,7039,7041,7084,7086,7133,7798,102399]);for(let t=4087;t<=4088;t++)e.add(t);for(let t=5896;t<=5899;t++)e.add(t);for(let t=7005;t<=7007;t++)e.add(t);for(let t=7057;t<=7070;t++)e.add(t);for(let t=7073;t<=7082;t++)e.add(t);for(let t=7109;t<=7128;t++)e.add(t);for(let t=7844;t<=7859;t++)e.add(t);return e}])},41818:(e,t,i)=>{i.d(t,{P:()=>o});var r=i(11282),n=i(34599),s=i(57444);async function o(e,t,i){const o=(0,r.en)(e);return(0,n.executeQueryForCount)(o,s.Z.from(t),{...i}).then((e=>e.data.count))}},5396:(e,t,i)=>{i.d(t,{G:()=>o});var r=i(11282),n=i(34599),s=i(57444);async function o(e,t,i){const o=(0,r.en)(e);return(0,n.executeQueryForIds)(o,s.Z.from(t),{...i}).then((e=>e.data.objectIds))}},4967:(e,t,i)=>{i.d(t,{F:()=>l,e:()=>a});var r=i(11282),n=i(34599),s=i(74889),o=i(57444);async function a(e,t,i){const r=await l(e,t,i);return s.default.fromJSON(r)}async function l(e,t,i){const s=(0,r.en)(e),a={...i},l=o.Z.from(t),{data:u}=await(0,n.executeQuery)(s,l,l.sourceSpatialReference,a);return u}},28694:(e,t,i)=>{i.d(t,{p:()=>s});var r=i(70586),n=i(69285);function s(e,t,i){if(!i||!i.features||!i.hasZ)return;const s=(0,n.k)(i.geometryType,t,e.outSpatialReference);if(!(0,r.Wi)(s))for(const e of i.features)s(e.geometry)}},98326:(e,t,i)=>{i.d(t,{Z:()=>c});var r,n=i(43697),s=i(96674),o=i(5600),a=(i(67676),i(75215)),l=i(52011);const u={1:{id:1,rotation:0,mirrored:!1},2:{id:2,rotation:0,mirrored:!0},3:{id:3,rotation:180,mirrored:!1},4:{id:4,rotation:180,mirrored:!0},5:{id:5,rotation:-90,mirrored:!0},6:{id:6,rotation:90,mirrored:!1},7:{id:7,rotation:90,mirrored:!0},8:{id:8,rotation:-90,mirrored:!1}};let p=r=class extends s.wq{constructor(e){super(e),this.contentType=null,this.exifInfo=null,this.id=null,this.globalId=null,this.keywords=null,this.name=null,this.parentGlobalId=null,this.parentObjectId=null,this.size=null,this.url=null}get orientationInfo(){const{exifInfo:e}=this,t=function(e){const{exifInfo:t,exifName:i,tagName:r}=e;if(!t||!i||!r)return null;const n=t.find((e=>e.name===i));return n?function(e){const{tagName:t,tags:i}=e;if(!i||!t)return null;const r=i.find((e=>e.name===t));return r&&r.value||null}({tagName:r,tags:n.tags}):null}({exifName:"Exif IFD0",tagName:"Orientation",exifInfo:e});return u[t]||null}clone(){return new r({contentType:this.contentType,exifInfo:this.exifInfo,id:this.id,globalId:this.globalId,keywords:this.keywords,name:this.name,parentGlobalId:this.parentGlobalId,parentObjectId:this.parentObjectId,size:this.size,url:this.url})}};(0,n._)([(0,o.Cb)({type:String})],p.prototype,"contentType",void 0),(0,n._)([(0,o.Cb)()],p.prototype,"exifInfo",void 0),(0,n._)([(0,o.Cb)({readOnly:!0})],p.prototype,"orientationInfo",null),(0,n._)([(0,o.Cb)({type:a.z8})],p.prototype,"id",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"globalId",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"keywords",void 0),(0,n._)([(0,o.Cb)({type:String})],p.prototype,"name",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"parentGlobalId",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"parentObjectId",void 0),(0,n._)([(0,o.Cb)({type:a.z8})],p.prototype,"size",void 0),(0,n._)([(0,o.Cb)({json:{read:!1}})],p.prototype,"url",void 0),p=r=(0,n._)([(0,l.j)("esri.layers.support.AttachmentInfo")],p);const c=p},56545:(e,t,i)=>{i.d(t,{Z:()=>d});var r,n=i(43697),s=i(96674),o=i(22974),a=i(5600),l=i(75215),u=i(52011),p=i(30556);let c=r=class extends s.wq{constructor(e){super(e),this.attachmentTypes=null,this.attachmentsWhere=null,this.cacheHint=void 0,this.keywords=null,this.globalIds=null,this.name=null,this.num=null,this.objectIds=null,this.returnMetadata=!1,this.size=null,this.start=null,this.where=null}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10}clone(){return new r((0,o.d9)({attachmentTypes:this.attachmentTypes,attachmentsWhere:this.attachmentsWhere,cacheHint:this.cacheHint,keywords:this.keywords,where:this.where,globalIds:this.globalIds,name:this.name,num:this.num,objectIds:this.objectIds,returnMetadata:this.returnMetadata,size:this.size,start:this.start}))}};(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],c.prototype,"attachmentTypes",void 0),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"attachmentsDefinitionExpression"},write:{target:"attachmentsDefinitionExpression"}}})],c.prototype,"attachmentsWhere",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],c.prototype,"cacheHint",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],c.prototype,"keywords",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"globalIds",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],c.prototype,"name",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],c.prototype,"num",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"objectIds",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{default:!1,write:!0}})],c.prototype,"returnMetadata",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],c.prototype,"size",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],c.prototype,"start",void 0),(0,n._)([(0,p.c)("start"),(0,p.c)("num")],c.prototype,"writeStart",null),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],c.prototype,"where",void 0),c=r=(0,n._)([(0,u.j)("esri.rest.support.AttachmentQuery")],c),c.from=(0,l.se)(c);const d=c},75935:(e,t,i)=>{i.d(t,{Z:()=>h});var r,n=i(43697),s=(i(66577),i(96674)),o=i(22974),a=i(5600),l=i(75215),u=i(52011),p=i(30556),c=i(10158),d=i(82971);let m=r=class extends s.wq{constructor(e){super(e),this.cacheHint=void 0,this.dynamicDataSource=void 0,this.gdbVersion=null,this.geometryPrecision=void 0,this.historicMoment=null,this.maxAllowableOffset=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.relationshipId=void 0,this.start=void 0,this.num=void 0,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.where=null}_writeHistoricMoment(e,t){t.historicMoment=e&&e.getTime()}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10,this.start>0&&null==this.where&&(t.definitionExpression="1=1")}clone(){return new r((0,o.d9)({cacheHint:this.cacheHint,dynamicDataSource:this.dynamicDataSource,gdbVersion:this.gdbVersion,geometryPrecision:this.geometryPrecision,historicMoment:this.historicMoment&&new Date(this.historicMoment.getTime()),maxAllowableOffset:this.maxAllowableOffset,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,relationshipId:this.relationshipId,start:this.start,num:this.num,returnGeometry:this.returnGeometry,where:this.where,returnZ:this.returnZ,returnM:this.returnM}))}};(0,n._)([(0,a.Cb)({type:Boolean,json:{write:!0}})],m.prototype,"cacheHint",void 0),(0,n._)([(0,a.Cb)({type:c.n,json:{write:!0}})],m.prototype,"dynamicDataSource",void 0),(0,n._)([(0,a.Cb)({type:String,json:{write:!0}})],m.prototype,"gdbVersion",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{write:!0}})],m.prototype,"geometryPrecision",void 0),(0,n._)([(0,a.Cb)({type:Date})],m.prototype,"historicMoment",void 0),(0,n._)([(0,p.c)("historicMoment")],m.prototype,"_writeHistoricMoment",null),(0,n._)([(0,a.Cb)({type:Number,json:{write:!0}})],m.prototype,"maxAllowableOffset",void 0),(0,n._)([(0,a.Cb)({type:[Number],json:{write:!0}})],m.prototype,"objectIds",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],m.prototype,"orderByFields",void 0),(0,n._)([(0,a.Cb)({type:[String],json:{write:!0}})],m.prototype,"outFields",void 0),(0,n._)([(0,a.Cb)({type:d.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],m.prototype,"outSpatialReference",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],m.prototype,"relationshipId",void 0),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],m.prototype,"start",void 0),(0,n._)([(0,p.c)("start"),(0,p.c)("num")],m.prototype,"writeStart",null),(0,n._)([(0,a.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],m.prototype,"num",void 0),(0,n._)([(0,a.Cb)({json:{write:!0}})],m.prototype,"returnGeometry",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"returnM",void 0),(0,n._)([(0,a.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],m.prototype,"returnZ",void 0),(0,n._)([(0,a.Cb)({type:String,json:{read:{source:"definitionExpression"},write:{target:"definitionExpression"}}})],m.prototype,"where",void 0),m=r=(0,n._)([(0,u.j)("esri.rest.support.RelationshipQuery")],m),m.from=(0,l.se)(m);const h=m},28141:(e,t,i)=>{i.d(t,{Z:()=>C});var r,n=i(43697),s=i(66577),o=i(92835),a=i(35454),l=i(96674),u=i(22974),p=i(70586),c=i(5600),d=i(75215),m=i(52011),h=i(30556),y=i(33955);i(67676);let f=r=class extends l.wq{constructor(e){super(e),this.groupByFields=void 0,this.topCount=void 0,this.orderByFields=void 0}clone(){return new r({groupByFields:this.groupByFields,topCount:this.topCount,orderByFields:this.orderByFields})}};(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],f.prototype,"groupByFields",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],f.prototype,"topCount",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],f.prototype,"orderByFields",void 0),f=r=(0,n._)([(0,m.j)("esri.rest.support.TopFilter")],f);const g=f;var b,R=i(82971);const v=new a.X({esriSpatialRelIntersects:"intersects",esriSpatialRelContains:"contains",esriSpatialRelCrosses:"crosses",esriSpatialRelDisjoint:"disjoint",esriSpatialRelEnvelopeIntersects:"envelope-intersects",esriSpatialRelIndexIntersects:"index-intersects",esriSpatialRelOverlaps:"overlaps",esriSpatialRelTouches:"touches",esriSpatialRelWithin:"within",esriSpatialRelRelation:"relation"}),w=new a.X({esriSRUnit_Meter:"meters",esriSRUnit_Kilometer:"kilometers",esriSRUnit_Foot:"feet",esriSRUnit_StatuteMile:"miles",esriSRUnit_NauticalMile:"nautical-miles",esriSRUnit_USNauticalMile:"us-nautical-miles"});let _=b=class extends l.wq{constructor(e){super(e),this.cacheHint=void 0,this.distance=void 0,this.geometry=null,this.geometryPrecision=void 0,this.maxAllowableOffset=void 0,this.num=void 0,this.objectIds=null,this.orderByFields=null,this.outFields=null,this.outSpatialReference=null,this.resultType=null,this.returnGeometry=!1,this.returnM=void 0,this.returnZ=void 0,this.start=void 0,this.spatialRelationship="intersects",this.timeExtent=null,this.topFilter=void 0,this.units=null,this.where="1=1"}writeStart(e,t){t.resultOffset=this.start,t.resultRecordCount=this.num||10}clone(){return new b((0,u.d9)({cacheHint:this.cacheHint,distance:this.distance,geometry:this.geometry,geometryPrecision:this.geometryPrecision,maxAllowableOffset:this.maxAllowableOffset,num:this.num,objectIds:this.objectIds,orderByFields:this.orderByFields,outFields:this.outFields,outSpatialReference:this.outSpatialReference,resultType:this.resultType,returnGeometry:this.returnGeometry,returnZ:this.returnZ,returnM:this.returnM,start:this.start,spatialRelationship:this.spatialRelationship,timeExtent:this.timeExtent,topFilter:this.topFilter,units:this.units,where:this.where}))}};(0,n._)([(0,c.Cb)({type:Boolean,json:{write:!0}})],_.prototype,"cacheHint",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:{overridePolicy:e=>({enabled:e>0})}}})],_.prototype,"distance",void 0),(0,n._)([(0,c.Cb)({types:s.qM,json:{read:y.im,write:!0}})],_.prototype,"geometry",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],_.prototype,"geometryPrecision",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{write:!0}})],_.prototype,"maxAllowableOffset",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{read:{source:"resultRecordCount"}}})],_.prototype,"num",void 0),(0,n._)([(0,c.Cb)({json:{write:!0}})],_.prototype,"objectIds",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],_.prototype,"orderByFields",void 0),(0,n._)([(0,c.Cb)({type:[String],json:{write:!0}})],_.prototype,"outFields",void 0),(0,n._)([(0,c.Cb)({type:R.Z,json:{read:{source:"outSR"},write:{target:"outSR"}}})],_.prototype,"outSpatialReference",void 0),(0,n._)([(0,c.Cb)({type:String,json:{write:!0}})],_.prototype,"resultType",void 0),(0,n._)([(0,c.Cb)({json:{write:!0}})],_.prototype,"returnGeometry",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"returnM",void 0),(0,n._)([(0,c.Cb)({type:Boolean,json:{write:{overridePolicy:e=>({enabled:e})}}})],_.prototype,"returnZ",void 0),(0,n._)([(0,c.Cb)({type:Number,json:{read:{source:"resultOffset"}}})],_.prototype,"start",void 0),(0,n._)([(0,h.c)("start"),(0,h.c)("num")],_.prototype,"writeStart",null),(0,n._)([(0,c.Cb)({type:String,json:{read:{source:"spatialRel",reader:v.read},write:{target:"spatialRel",writer:v.write}}})],_.prototype,"spatialRelationship",void 0),(0,n._)([(0,c.Cb)({type:o.Z,json:{write:!0}})],_.prototype,"timeExtent",void 0),(0,n._)([(0,c.Cb)({type:g,json:{write:!0}})],_.prototype,"topFilter",void 0),(0,n._)([(0,c.Cb)({type:String,json:{read:w.read,write:{writer:w.write,overridePolicy(e){return{enabled:(0,p.pC)(e)&&(0,p.pC)(this.distance)&&this.distance>0}}}}})],_.prototype,"units",void 0),(0,n._)([(0,c.Cb)({type:String,json:{write:!0}})],_.prototype,"where",void 0),_=b=(0,n._)([(0,m.j)("esri.rest.support.TopFeaturesQuery")],_),_.from=(0,d.se)(_);const C=_}}]);
@@ -1 +1 @@
1
- "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6636,661],{10661:(e,a,t)=>{t.d(a,{s:()=>n});var r=t(39020);class n{constructor(){this._observers=[]}observe(e){return this._observers.includes(e)||this._observers.push(e),new r.X(this._observers,e)}notify(){const e=this._observers.slice();for(let a=0;a<e.length;++a){const t=e[a];t.onInvalidated(),t.onCommitted()}}}},87344:(e,a,t)=>{t.d(a,{T:()=>r});const r={BingMapsLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9513)]).then(t.bind(t,2723))).default,BuildingSceneLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(719),t.e(9268),t.e(7698),t.e(223)]).then(t.bind(t,30223))).default,CSVLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(7827)]).then(t.bind(t,45425))).default,DimensionLayer:async()=>(await Promise.all([t.e(4547),t.e(958),t.e(81)]).then(t.bind(t,40081))).default,ElevationLayer:async()=>(await Promise.all([t.e(8794),t.e(5207)]).then(t.bind(t,49932))).default,FeatureLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(4202)]).then(t.bind(t,19238))).default,GroupLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9)]).then(t.bind(t,89348))).default,GeoRSSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(7062)]).then(t.bind(t,3723))).default,GeoJSONLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(7202)]).then(t.bind(t,23477))).default,ImageryLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(4588),t.e(4599),t.e(8363),t.e(4242),t.e(4028)]).then(t.bind(t,66210))).default,ImageryTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(8794),t.e(8363),t.e(4242),t.e(3645),t.e(3548)]).then(t.bind(t,92045))).default,IntegratedMeshLayer:async()=>(await Promise.all([t.e(2710),t.e(4547),t.e(719),t.e(4046)]).then(t.bind(t,9310))).default,KMLLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(739)]).then(t.bind(t,42756))).default,LineOfSightLayer:async()=>(await Promise.all([t.e(4547),t.e(9790),t.e(1773),t.e(958),t.e(7160)]).then(t.bind(t,67160))).default,MapImageLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(4436),t.e(7374)]).then(t.bind(t,27374))).default,MapNotesLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(9956)]).then(t.bind(t,62128))).default,OGCFeatureLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(2855)]).then(t.bind(t,88068))).default,OpenStreetMapLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903),t.e(6237)]).then(t.bind(t,66237))).default,OrientedImageryLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(9356)]).then(t.bind(t,76604))).default,PointCloudLayer:async()=>(await Promise.all([t.e(2710),t.e(1773),t.e(5468)]).then(t.bind(t,10608))).default,RouteLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(6925)]).then(t.bind(t,40153))).default,SceneLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(719),t.e(9268),t.e(7698),t.e(7476)]).then(t.bind(t,57476))).default,StreamLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(5004)]).then(t.bind(t,88387))).default,SubtypeGroupLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(6015),t.e(2374)]).then(t.bind(t,30359))).default,TileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(8794),t.e(4436),t.e(8636)]).then(t.bind(t,98636))).default,UnknownLayer:async()=>(await t.e(4166).then(t.bind(t,44166))).default,UnsupportedLayer:async()=>(await t.e(9296).then(t.bind(t,39296))).default,VectorTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(8794),t.e(4325),t.e(1785),t.e(7272)]).then(t.bind(t,24109))).default,VoxelLayer:async()=>(await Promise.all([t.e(2710),t.e(6794)]).then(t.bind(t,28865))).default,WebTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903)]).then(t.bind(t,16199))).default,WFSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(3810)]).then(t.bind(t,12653))).default,WMSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(8383)]).then(t.bind(t,25906))).default,WMTSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903),t.e(5853)]).then(t.bind(t,55853))).default}},28008:(e,a,t)=>{t.r(a),t.d(a,{fromItem:()=>o,selectLayerClassPath:()=>y});var r=t(20102),n=t(87344),s=t(15235),l=t(18062),i=t(14661),c=t(96187);function o(e){return!e.portalItem||e.portalItem instanceof s.default||(e={...e,portalItem:new s.default(e.portalItem)}),function(e){return e.load().then(y).then(u)}(e.portalItem).then((a=>{const t={portalItem:e.portalItem,...a.properties};return new(0,a.constructor)(t)}))}function y(e){switch(e.type){case"Map Service":return(a=e,(0,c.b)(a.url).then((e=>e.tileInfo))).then((e=>e?{className:"TileLayer"}:{className:"MapImageLayer"}));case"Feature Service":return function(e){return(0,i._$)(e,"Oriented Imagery Layer")?function(e){return e.load().then((()=>e.fetchData())).then((e=>e.coverage?{className:"GroupLayer"}:{className:"OrientedImageryLayer",properties:e}))}(e):d(e).then((e=>{if("object"==typeof e){const a={};return null!=e.id&&(a.layerId=e.id),{className:e.className||"FeatureLayer",properties:a}}return{className:"GroupLayer"}}))}(e);case"Feature Collection":return async function(e){await e.load();const a=(0,i._$)(e,"Map Notes"),t=(0,i._$)(e,"Markup");if(a||t)return{className:"MapNotesLayer"};if((0,i._$)(e,"Route Layer"))return{className:"RouteLayer"};const r=await e.fetchData();return 1===(0,l.getNumLayersAndTables)(r)?{className:"FeatureLayer"}:{className:"GroupLayer"}}(e);case"Scene Service":return function(e){return d(e).then((a=>{if("object"==typeof a){const t={};let r;if(null!=a.id?(t.layerId=a.id,r=`${e.url}/layers/${a.id}`):r=e.url,Array.isArray(e.typeKeywords)&&e.typeKeywords.length>0){const a={IntegratedMesh:"IntegratedMeshLayer","3DObject":"SceneLayer",Point:"SceneLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};for(const t of Object.keys(a))if(e.typeKeywords.includes(t))return{className:a[t]}}return(0,c.b)(r).then((e=>{let a="SceneLayer";const r={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};return e&&e.layerType&&r[e.layerType]&&(a=r[e.layerType]),{className:a,properties:t}}))}return!1===a?(0,c.b)(e.url).then((e=>"Voxel"===e?.layerType?{className:"VoxelLayer"}:{className:"GroupLayer"})):{className:"GroupLayer"}}))}(e);case"Image Service":return async function(e){await e.load();const a=e.typeKeywords?.map((e=>e.toLowerCase()))??[];if(a.includes("elevation 3d layer"))return{className:"ElevationLayer"};if(a.includes("tiled imagery"))return{className:"ImageryTileLayer"};const t=(await e.fetchData())?.layerType;if("ArcGISTiledImageServiceLayer"===t)return{className:"ImageryTileLayer"};if("ArcGISImageServiceLayer"===t)return{className:"ImageryLayer"};const r=await(0,c.b)(e.url),n=r.cacheType?.toLowerCase(),s=r.capabilities?.toLowerCase().includes("tilesonly");return"map"===n||s?{className:"ImageryTileLayer"}:{className:"ImageryLayer"}}(e);case"Stream Service":case"Feed":return{className:"StreamLayer"};case"Vector Tile Service":return{className:"VectorTileLayer"};case"GeoJson":return{className:"GeoJSONLayer"};case"CSV":return{className:"CSVLayer"};case"KML":return{className:"KMLLayer"};case"WFS":return{className:"WFSLayer"};case"WMTS":return{className:"WMTSLayer"};case"WMS":return{className:"WMSLayer"};default:return Promise.reject(new r.Z("portal:unknown-item-type","Unknown item type '${type}'",{type:e.type}))}var a}function u(e){return(0,n.T[e.className])().then((a=>({constructor:a,properties:e.properties})))}function d(e){return!e.url||e.url.match(/\/\d+$/)?Promise.resolve({}):e.load().then((()=>e.fetchData())).then((async a=>{if("Feature Service"===e.type){const t=m(await(0,l.preprocessFSItemData)(a,e.url));if("object"==typeof t){const e=(0,l.getSubtypeGroupLayerIds)(a);t.className=e.includes(t.id)?"SubtypeGroupLayer":"FeatureLayer"}return t}return(0,l.getNumLayersAndTables)(a)>0?m(a):(0,c.b)(e.url).then(m)}))}function m(e){return 1===(0,l.getNumLayersAndTables)(e)&&{id:(0,l.getFirstLayerOrTableId)(e)}}}}]);
1
+ "use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[6636,661],{10661:(e,a,t)=>{t.d(a,{s:()=>n});var r=t(39020);class n{constructor(){this._observers=[]}observe(e){return this._observers.includes(e)||this._observers.push(e),new r.X(this._observers,e)}notify(){const e=this._observers.slice();for(let a=0;a<e.length;++a){const t=e[a];t.onInvalidated(),t.onCommitted()}}}},87344:(e,a,t)=>{t.d(a,{T:()=>r});const r={BingMapsLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9513)]).then(t.bind(t,2723))).default,BuildingSceneLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(719),t.e(9268),t.e(7698),t.e(223)]).then(t.bind(t,30223))).default,CSVLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(7827)]).then(t.bind(t,45425))).default,DimensionLayer:async()=>(await Promise.all([t.e(4547),t.e(958),t.e(81)]).then(t.bind(t,40081))).default,ElevationLayer:async()=>(await Promise.all([t.e(8794),t.e(5207)]).then(t.bind(t,49932))).default,FeatureLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(4202)]).then(t.bind(t,19238))).default,GroupLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9)]).then(t.bind(t,89348))).default,GeoRSSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(7062)]).then(t.bind(t,3723))).default,GeoJSONLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(7202)]).then(t.bind(t,23477))).default,ImageryLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(4588),t.e(4599),t.e(8363),t.e(4242),t.e(4028)]).then(t.bind(t,66210))).default,ImageryTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(8794),t.e(8363),t.e(4242),t.e(3645),t.e(2592)]).then(t.bind(t,92045))).default,IntegratedMeshLayer:async()=>(await Promise.all([t.e(2710),t.e(4547),t.e(719),t.e(4046)]).then(t.bind(t,9310))).default,KMLLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(739)]).then(t.bind(t,42756))).default,LineOfSightLayer:async()=>(await Promise.all([t.e(4547),t.e(9790),t.e(1773),t.e(958),t.e(7160)]).then(t.bind(t,67160))).default,MapImageLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(4436),t.e(7374)]).then(t.bind(t,27374))).default,MapNotesLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(9956)]).then(t.bind(t,62128))).default,OGCFeatureLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(2855)]).then(t.bind(t,88068))).default,OpenStreetMapLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903),t.e(6237)]).then(t.bind(t,66237))).default,OrientedImageryLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(9356)]).then(t.bind(t,76604))).default,PointCloudLayer:async()=>(await Promise.all([t.e(2710),t.e(1773),t.e(5468)]).then(t.bind(t,10608))).default,RouteLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(6925)]).then(t.bind(t,40153))).default,SceneLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(6015),t.e(9238),t.e(719),t.e(9268),t.e(7698),t.e(7476)]).then(t.bind(t,57476))).default,StreamLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(5004)]).then(t.bind(t,88387))).default,SubtypeGroupLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(6015),t.e(2374)]).then(t.bind(t,30359))).default,TileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(8794),t.e(4436),t.e(8636)]).then(t.bind(t,98636))).default,UnknownLayer:async()=>(await t.e(4166).then(t.bind(t,44166))).default,UnsupportedLayer:async()=>(await t.e(9296).then(t.bind(t,39296))).default,VectorTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(8794),t.e(4325),t.e(1785),t.e(7272)]).then(t.bind(t,24109))).default,VoxelLayer:async()=>(await Promise.all([t.e(2710),t.e(6794)]).then(t.bind(t,28865))).default,WebTileLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903)]).then(t.bind(t,16199))).default,WFSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(4547),t.e(9790),t.e(1773),t.e(4992),t.e(8476),t.e(1423),t.e(4588),t.e(911),t.e(5546),t.e(3810)]).then(t.bind(t,12653))).default,WMSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9790),t.e(1773),t.e(8383)]).then(t.bind(t,25906))).default,WMTSLayer:async()=>(await Promise.all([t.e(2710),t.e(1612),t.e(9903),t.e(5853)]).then(t.bind(t,55853))).default}},28008:(e,a,t)=>{t.r(a),t.d(a,{fromItem:()=>o,selectLayerClassPath:()=>y});var r=t(20102),n=t(87344),s=t(15235),l=t(18062),i=t(14661),c=t(96187);function o(e){return!e.portalItem||e.portalItem instanceof s.default||(e={...e,portalItem:new s.default(e.portalItem)}),function(e){return e.load().then(y).then(u)}(e.portalItem).then((a=>{const t={portalItem:e.portalItem,...a.properties};return new(0,a.constructor)(t)}))}function y(e){switch(e.type){case"Map Service":return(a=e,(0,c.b)(a.url).then((e=>e.tileInfo))).then((e=>e?{className:"TileLayer"}:{className:"MapImageLayer"}));case"Feature Service":return function(e){return(0,i._$)(e,"Oriented Imagery Layer")?function(e){return e.load().then((()=>e.fetchData())).then((e=>e.coverage?{className:"GroupLayer"}:{className:"OrientedImageryLayer",properties:e}))}(e):d(e).then((e=>{if("object"==typeof e){const a={};return null!=e.id&&(a.layerId=e.id),{className:e.className||"FeatureLayer",properties:a}}return{className:"GroupLayer"}}))}(e);case"Feature Collection":return async function(e){await e.load();const a=(0,i._$)(e,"Map Notes"),t=(0,i._$)(e,"Markup");if(a||t)return{className:"MapNotesLayer"};if((0,i._$)(e,"Route Layer"))return{className:"RouteLayer"};const r=await e.fetchData();return 1===(0,l.getNumLayersAndTables)(r)?{className:"FeatureLayer"}:{className:"GroupLayer"}}(e);case"Scene Service":return function(e){return d(e).then((a=>{if("object"==typeof a){const t={};let r;if(null!=a.id?(t.layerId=a.id,r=`${e.url}/layers/${a.id}`):r=e.url,Array.isArray(e.typeKeywords)&&e.typeKeywords.length>0){const a={IntegratedMesh:"IntegratedMeshLayer","3DObject":"SceneLayer",Point:"SceneLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};for(const t of Object.keys(a))if(e.typeKeywords.includes(t))return{className:a[t]}}return(0,c.b)(r).then((e=>{let a="SceneLayer";const r={Point:"SceneLayer","3DObject":"SceneLayer",IntegratedMesh:"IntegratedMeshLayer",PointCloud:"PointCloudLayer",Building:"BuildingSceneLayer"};return e&&e.layerType&&r[e.layerType]&&(a=r[e.layerType]),{className:a,properties:t}}))}return!1===a?(0,c.b)(e.url).then((e=>"Voxel"===e?.layerType?{className:"VoxelLayer"}:{className:"GroupLayer"})):{className:"GroupLayer"}}))}(e);case"Image Service":return async function(e){await e.load();const a=e.typeKeywords?.map((e=>e.toLowerCase()))??[];if(a.includes("elevation 3d layer"))return{className:"ElevationLayer"};if(a.includes("tiled imagery"))return{className:"ImageryTileLayer"};const t=(await e.fetchData())?.layerType;if("ArcGISTiledImageServiceLayer"===t)return{className:"ImageryTileLayer"};if("ArcGISImageServiceLayer"===t)return{className:"ImageryLayer"};const r=await(0,c.b)(e.url),n=r.cacheType?.toLowerCase(),s=r.capabilities?.toLowerCase().includes("tilesonly");return"map"===n||s?{className:"ImageryTileLayer"}:{className:"ImageryLayer"}}(e);case"Stream Service":case"Feed":return{className:"StreamLayer"};case"Vector Tile Service":return{className:"VectorTileLayer"};case"GeoJson":return{className:"GeoJSONLayer"};case"CSV":return{className:"CSVLayer"};case"KML":return{className:"KMLLayer"};case"WFS":return{className:"WFSLayer"};case"WMTS":return{className:"WMTSLayer"};case"WMS":return{className:"WMSLayer"};default:return Promise.reject(new r.Z("portal:unknown-item-type","Unknown item type '${type}'",{type:e.type}))}var a}function u(e){return(0,n.T[e.className])().then((a=>({constructor:a,properties:e.properties})))}function d(e){return!e.url||e.url.match(/\/\d+$/)?Promise.resolve({}):e.load().then((()=>e.fetchData())).then((async a=>{if("Feature Service"===e.type){const t=m(await(0,l.preprocessFSItemData)(a,e.url));if("object"==typeof t){const e=(0,l.getSubtypeGroupLayerIds)(a);t.className=e.includes(t.id)?"SubtypeGroupLayer":"FeatureLayer"}return t}return(0,l.getNumLayersAndTables)(a)>0?m(a):(0,c.b)(e.url).then(m)}))}function m(e){return 1===(0,l.getNumLayersAndTables)(e)&&{id:(0,l.getFirstLayerOrTableId)(e)}}}}]);