@arcgis/core 4.33.0-next.20250204 → 4.33.0-next.20250206
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/components/assets/icon/dualImageArea16.json +1 -0
- package/assets/components/assets/icon/dualImageArea24.json +1 -0
- package/assets/components/assets/icon/dualImageArea32.json +1 -0
- package/assets/components/assets/icon/dualImageDistance16.json +1 -0
- package/assets/components/assets/icon/dualImageDistance24.json +1 -0
- package/assets/components/assets/icon/dualImageDistance32.json +1 -0
- package/assets/components/assets/icon/dualImageLocation16.json +1 -0
- package/assets/components/assets/icon/dualImageLocation24.json +1 -0
- package/assets/components/assets/icon/dualImageLocation32.json +1 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/06f693780f70e5a627c4.js +1 -0
- package/assets/esri/core/workers/chunks/{24a86c52c8bdd0b5eb4d.js → 09a99c556089c166d1f8.js} +1 -1
- package/assets/esri/core/workers/chunks/15f850c9a1154fc57e5a.js +1 -0
- package/assets/esri/core/workers/chunks/{9b4f471fcd8a3b5e089f.js → 192569dfa7c0ea8dd864.js} +1 -1
- package/assets/esri/core/workers/chunks/1a2e1a414e651e988435.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/24e47f748f0e4f815c6e.js +1 -0
- package/assets/esri/core/workers/chunks/28374a64790342e1b5ae.js +1 -0
- package/assets/esri/core/workers/chunks/{c3f03ccabca691186aad.js → 287362f9af132fafe4de.js} +1 -1
- package/assets/esri/core/workers/chunks/{ad215219e5eef8598745.js → 28dbbfc44cc2bdcd221d.js} +1 -1
- package/assets/esri/core/workers/chunks/2adc533dadcb018a9755.js +1 -0
- package/assets/esri/core/workers/chunks/308ec51ff4a66f7fcb0d.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/333091ab2e267652ed56.js +1 -0
- package/assets/esri/core/workers/chunks/354531dc2f0dea2ad96f.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/38cd7745b8ef1b8b6196.js +1 -0
- package/assets/esri/core/workers/chunks/{8a1e4f65fc81aba7a704.js → 4122d10bc910e888eee1.js} +1 -1
- package/assets/esri/core/workers/chunks/41cd1a5c99ab3bbd1fb4.js +1 -0
- package/assets/esri/core/workers/chunks/433576983754f690bcc7.js +1 -0
- package/assets/esri/core/workers/chunks/{b1269b51cef3e11c85e3.js → 48ecc5a74fecbb2b9c6f.js} +1 -1
- package/assets/esri/core/workers/chunks/{b8a519d5d24b2e728ff8.js → 5a25cef6355fd20e44e7.js} +2 -2
- package/assets/esri/core/workers/chunks/{b8a519d5d24b2e728ff8.js.LICENSE.txt → 5a25cef6355fd20e44e7.js.LICENSE.txt} +1 -1
- package/assets/esri/core/workers/chunks/{8edae4ca2b18a219a43e.js → 5e7f16b312077ca8c18d.js} +1 -1
- package/assets/esri/core/workers/chunks/{7a0415db78c68d31733f.js → 6039da57a2adedd3b83f.js} +1 -1
- package/assets/esri/core/workers/chunks/72cf9192292e5c85c6df.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/73d03c208242778e67bf.js +1 -0
- package/assets/esri/core/workers/chunks/{e4f82b5b50996b1ae48e.js → 746c964cf07e4306f21f.js} +1 -1
- package/assets/esri/core/workers/chunks/77764ca90bdd13ee2167.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/{723a9fba144e2fa6d017.js → 7cb09e58bcc537ec1f7a.js} +1 -1
- package/assets/esri/core/workers/chunks/{07360fde6ea65664e6ca.js → 82d26884127ed772cc4b.js} +1 -1
- package/assets/esri/core/workers/chunks/842db06ce62758fab1e7.js +1 -0
- package/assets/esri/core/workers/chunks/{60cd8f4bba3e682ba57e.js → 91d2bdfa6e34c10b7f50.js} +1 -1
- package/assets/esri/core/workers/chunks/{12dd892cf61a76fb40ad.js → 991e0f619f1f81f94d56.js} +1 -1
- package/assets/esri/core/workers/chunks/9a27824d94df702e6e28.js +1 -0
- package/assets/esri/core/workers/chunks/{610b33b7291cffcc4e5d.js → a42ae5d5e5f66d120b4d.js} +1 -1
- package/assets/esri/core/workers/chunks/a5e9ea13e844a62b2a7f.js +1 -0
- package/assets/esri/core/workers/chunks/b21b152fa15896577242.js.LICENSE.txt +1 -1
- package/assets/esri/core/workers/chunks/b43d88b6e7dc4ab13599.js +1 -0
- package/assets/esri/core/workers/chunks/{da77eefaad83c0644380.js → b8fae500c69ca2cff62a.js} +1 -1
- package/assets/esri/core/workers/chunks/b9d9a1dc3c5d799e2685.js +1 -0
- package/assets/esri/core/workers/chunks/{9c5c6ecaf5be24279fa5.js → ddc30044f61a2c2df3fe.js} +1 -1
- package/assets/esri/core/workers/chunks/e26dc0c1654316bb1558.js +1 -0
- package/assets/esri/core/workers/chunks/ef6279f5c63ab1e88c71.js +1 -0
- package/assets/esri/core/workers/chunks/{0711d3ad4d403bcfdcad.js → f117a89d1f4001a1f9f0.js} +1 -1
- package/assets/esri/core/workers/chunks/f4e48bbdbc9da10ec71a.js +1 -0
- package/assets/esri/core/workers/chunks/f9e48205178a5a804d38.js +1 -0
- package/assets/esri/themes/base/widgets/_Directions.scss +74 -17
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/chunks/ColorMaterial.glsl.js +4 -5
- package/chunks/Pattern.glsl.js +1 -1
- package/chunks/WaterSurface.glsl.js +2 -2
- package/geometry/operators/projectOperator.js +1 -1
- package/geometry/operators/shapePreservingProjectOperator.js +1 -1
- package/geometry/support/meshUtils/elevation.js +1 -1
- package/interfaces.d.ts +76 -28
- package/layers/Layer.js +1 -1
- package/layers/graphics/data/FeatureStore.js +1 -1
- package/layers/graphics/sources/geojson/GeoJSONSourceWorker.js +1 -1
- package/layers/graphics/sources/support/MemorySourceWorker.js +1 -1
- package/layers/ogc/wcsUtils.js +1 -1
- package/layers/support/RasterFunctionTemplate.js +1 -1
- package/layers/support/Sublayer.js +1 -1
- package/layers/support/capabilities.js +1 -1
- package/layers/support/featureLayerUtils.js +1 -1
- package/layers/support/rasterDatasets/WCSRaster.js +1 -1
- package/layers/support/rasterDatasets/multipartParser.js +1 -1
- package/layers/support/rasterDatasets/wcsCapabilitiesParser.js +1 -1
- package/layers/support/rasterFunctionUtils.d.ts +2 -1
- package/layers/support/rasterFunctionUtils.js +1 -1
- package/layers/support/rasterFunctions/creators/createDataManagementFunctions.js +1 -1
- package/layers/support/serviceCapabilitiesUtils.js +1 -1
- package/package.json +2 -2
- package/rest/query/operations/queryAttachments.js +1 -1
- package/rest/support/AttachmentQuery.js +1 -1
- package/smartMapping/support/adapters/InMemoryLayerAdapter.js +1 -1
- package/smartMapping/support/adapters/support/histogramUtils.js +1 -1
- package/support/revision.js +1 -1
- package/symbols/cim/CIMSymbolRasterizer.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapResources.js +1 -1
- package/views/2d/layers/FeatureLayerView2D.js +1 -1
- package/views/2d/layers/GraphicsLayerView2D.js +1 -1
- package/views/2d/layers/ImageryLayerView2D.js +1 -1
- package/views/2d/layers/LayerView2D.js +1 -1
- package/views/2d/layers/MapImageLayerView2D.js +1 -1
- package/views/2d/layers/TileLayerView2D.js +1 -1
- package/views/2d/layers/graphics/HighlightGraphicContainer.js +1 -1
- package/views/2d/layers/imagery/BaseImageryTileSubView2D.js +1 -1
- package/views/2d/layers/support/util.js +1 -1
- package/views/3d/environment/ChapmanAtmosphere.js +1 -1
- package/views/3d/layers/MediaLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DSymbolLayer.js +1 -1
- package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
- package/views/3d/terrain/OverlayManager.js +1 -1
- package/views/3d/terrain/OverlayRenderer.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/webgl-engine/Stage.js +1 -1
- package/views/3d/webgl-engine/effects/haze/Haze.js +1 -1
- package/views/3d/webgl-engine/parts/RenderView.js +1 -1
- package/views/3d/webgl-engine/parts/ScreenshotManager.js +1 -1
- package/views/LayerViewManager.js +1 -1
- package/views/SceneView.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceSnappingSourceWorker.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTileCache.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTileStore.js +1 -1
- package/views/interactive/snapping/featureSources/featureServiceSource/FeatureServiceTiledFetcher.js +1 -1
- package/views/layers/support/MapServiceLayerViewHelper.js +1 -1
- package/widgets/Attachments/AttachmentsViewModel.js +1 -1
- package/widgets/Directions.js +1 -1
- package/widgets/Editor/UpdateWorkflow.js +1 -1
- package/widgets/Editor/support/EditorItem.js +1 -1
- package/widgets/Feature/FeatureExpression/FeatureExpressionViewModel.js +1 -1
- package/widgets/Feature/FeatureViewModel.js +1 -1
- package/widgets/Feature/support/arcadeFeatureUtils.js +1 -1
- package/widgets/NavigationToggle/NavigationToggleViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/MeasurementAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/components/ImageLocationWidget.js +1 -1
- package/widgets/support/geolocationUtils.js +1 -1
- package/assets/esri/core/workers/chunks/04306c2760c1f5b19966.js +0 -1
- package/assets/esri/core/workers/chunks/1e3ab66d0e8a7f160f33.js +0 -1
- package/assets/esri/core/workers/chunks/380d37ceb8cf52bad190.js +0 -1
- package/assets/esri/core/workers/chunks/39e38aab86dcee3f79be.js +0 -1
- package/assets/esri/core/workers/chunks/3ce826ebf0692363309d.js +0 -1
- package/assets/esri/core/workers/chunks/402de76b5de05615e111.js +0 -1
- package/assets/esri/core/workers/chunks/69d307758262e5d7a32e.js +0 -1
- package/assets/esri/core/workers/chunks/6dee40b94f94ee7bc4e4.js +0 -1
- package/assets/esri/core/workers/chunks/7a3e4cb5f64dac2cfe0e.js +0 -1
- package/assets/esri/core/workers/chunks/7e4d72279cc599b7029c.js +0 -1
- package/assets/esri/core/workers/chunks/8438fba57e82e4cc7c11.js +0 -1
- package/assets/esri/core/workers/chunks/92155d112ebb6a4c6c6e.js +0 -1
- package/assets/esri/core/workers/chunks/ba37ab9e560644dc1f18.js +0 -1
- package/assets/esri/core/workers/chunks/bbbe5d6cb8b737811c84.js +0 -1
- package/assets/esri/core/workers/chunks/bf26f58210755875748c.js +0 -1
- package/assets/esri/core/workers/chunks/c7a94e569c905f97244a.js +0 -1
- package/assets/esri/core/workers/chunks/d8c762ca94e3a11b125d.js +0 -1
- package/assets/esri/core/workers/chunks/dbc447413ab40a79ba87.js +0 -1
- package/assets/esri/core/workers/chunks/f48ef415b90edc7ccadd.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2015],{87317:(e,t,s)=>{s.d(t,{a:()=>_,b:()=>c,c:()=>r,d:()=>f,e:()=>I,f:()=>y,g:()=>a,h:()=>x,j:()=>d,l:()=>p,n:()=>g,s:()=>i,t:()=>m});var n=s(34304);function r(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function i(e,t,s,n,r){return e[0]=t,e[1]=s,e[2]=n,e[3]=r,e}function a(e,t,s){return e[0]=t[0]+s[0],e[1]=t[1]+s[1],e[2]=t[2]+s[2],e[3]=t[3]+s[3],e}function o(e,t,s){return e[0]=t[0]-s[0],e[1]=t[1]-s[1],e[2]=t[2]-s[2],e[3]=t[3]-s[3],e}function l(e,t,s){return e[0]=t[0]*s[0],e[1]=t[1]*s[1],e[2]=t[2]*s[2],e[3]=t[3]*s[3],e}function h(e,t,s){return e[0]=t[0]/s[0],e[1]=t[1]/s[1],e[2]=t[2]/s[2],e[3]=t[3]/s[3],e}function c(e,t,s){return e[0]=t[0]*s,e[1]=t[1]*s,e[2]=t[2]*s,e[3]=t[3]*s,e}function u(e,t){const s=t[0]-e[0],n=t[1]-e[1],r=t[2]-e[2],i=t[3]-e[3];return Math.sqrt(s*s+n*n+r*r+i*i)}function f(e,t){const s=t[0]-e[0],n=t[1]-e[1],r=t[2]-e[2],i=t[3]-e[3];return s*s+n*n+r*r+i*i}function d(e){const t=e[0],s=e[1],n=e[2],r=e[3];return Math.sqrt(t*t+s*s+n*n+r*r)}function y(e){const t=e[0],s=e[1],n=e[2],r=e[3];return t*t+s*s+n*n+r*r}function g(e,t){const s=t[0],n=t[1],r=t[2],i=t[3];let a=s*s+n*n+r*r+i*i;return a>0&&(a=1/Math.sqrt(a),e[0]=s*a,e[1]=n*a,e[2]=r*a,e[3]=i*a),e}function x(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function p(e,t,s,n){const r=t[0],i=t[1],a=t[2],o=t[3];return e[0]=r+n*(s[0]-r),e[1]=i+n*(s[1]-i),e[2]=a+n*(s[2]-a),e[3]=o+n*(s[3]-o),e}function m(e,t,s){const n=t[0],r=t[1],i=t[2],a=t[3];return e[0]=s[0]*n+s[4]*r+s[8]*i+s[12]*a,e[1]=s[1]*n+s[5]*r+s[9]*i+s[13]*a,e[2]=s[2]*n+s[6]*r+s[10]*i+s[14]*a,e[3]=s[3]*n+s[7]*r+s[11]*i+s[15]*a,e}function _(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]}function I(e,t){const s=e[0],r=e[1],i=e[2],a=e[3],o=t[0],l=t[1],h=t[2],c=t[3],u=(0,n.FD)();return Math.abs(s-o)<=u*Math.max(1,Math.abs(s),Math.abs(o))&&Math.abs(r-l)<=u*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(i-h)<=u*Math.max(1,Math.abs(i),Math.abs(h))&&Math.abs(a-c)<=u*Math.max(1,Math.abs(a),Math.abs(c))}const b=o,M=l,w=h,P=u,T=f,A=d,D=y;Object.freeze(Object.defineProperty({__proto__:null,add:a,ceil:function(e,t){return e[0]=Math.ceil(t[0]),e[1]=Math.ceil(t[1]),e[2]=Math.ceil(t[2]),e[3]=Math.ceil(t[3]),e},copy:r,copyVec3:function(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},dist:P,distance:u,div:w,divide:h,dot:x,equals:I,exactEquals:_,floor:function(e,t){return e[0]=Math.floor(t[0]),e[1]=Math.floor(t[1]),e[2]=Math.floor(t[2]),e[3]=Math.floor(t[3]),e},inverse:function(e,t){return e[0]=1/t[0],e[1]=1/t[1],e[2]=1/t[2],e[3]=1/t[3],e},len:A,length:d,lerp:p,max:function(e,t,s){return e[0]=Math.max(t[0],s[0]),e[1]=Math.max(t[1],s[1]),e[2]=Math.max(t[2],s[2]),e[3]=Math.max(t[3],s[3]),e},min:function(e,t,s){return e[0]=Math.min(t[0],s[0]),e[1]=Math.min(t[1],s[1]),e[2]=Math.min(t[2],s[2]),e[3]=Math.min(t[3],s[3]),e},mul:M,multiply:l,negate:function(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e[3]=-t[3],e},normalize:g,random:function(e,t=1){const s=n.Ov;let r,i,a,o,l,h;do{r=2*s()-1,i=2*s()-1,l=r*r+i*i}while(l>=1);do{a=2*s()-1,o=2*s()-1,h=a*a+o*o}while(h>=1);const c=Math.sqrt((1-l)/h);return e[0]=t*r,e[1]=t*i,e[2]=t*a*c,e[3]=t*o*c,e},round:function(e,t){return e[0]=Math.round(t[0]),e[1]=Math.round(t[1]),e[2]=Math.round(t[2]),e[3]=Math.round(t[3]),e},scale:c,scaleAndAdd:function(e,t,s,n){return e[0]=t[0]+s[0]*n,e[1]=t[1]+s[1]*n,e[2]=t[2]+s[2]*n,e[3]=t[3]+s[3]*n,e},set:i,sqrDist:T,sqrLen:D,squaredDistance:f,squaredLength:y,str:function(e){return"vec4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"},sub:b,subtract:o,transformMat4:m,transformQuat:function(e,t,s){const n=t[0],r=t[1],i=t[2],a=s[0],o=s[1],l=s[2],h=s[3],c=h*n+o*i-l*r,u=h*r+l*n-a*i,f=h*i+a*r-o*n,d=-a*n-o*r-l*i;return e[0]=c*h+d*-a+u*-l-f*-o,e[1]=u*h+d*-o+f*-a-c*-l,e[2]=f*h+d*-l+c*-o-u*-a,e[3]=t[3],e}},Symbol.toStringTag,{value:"Module"}))},40876:(e,t,s)=>{s.d(t,{TS:()=>i,Tf:()=>c,V6:()=>r,c4:()=>a,qh:()=>h,z$:()=>l});const n={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function r(e){return!!n[e]||!!n[e.toLowerCase()]}function i(e){return n[e]??n[e.toLowerCase()]}function a(e){return[...i(e)]}function o(e,t,s){s<0&&++s,s>1&&--s;const n=6*s;return n<1?e+(t-e)*n:2*s<1?t:3*s<2?e+(t-e)*(2/3-s)*6:e}function l(e,t,s,n=1){const r=(e%360+360)%360/360,i=s<=.5?s*(t+1):s+t-s*t,a=2*s-i;return[Math.round(255*o(a,i,r+1/3)),Math.round(255*o(a,i,r)),Math.round(255*o(a,i,r-1/3)),n]}function h(e){const t=e.length>5,s=t?8:4,n=(1<<s)-1,r=t?1:17,i=t?9===e.length:5===e.length;let a=Number("0x"+e.slice(1));if(isNaN(a))return null;const o=[0,0,0,1];let l;return i&&(l=a&n,a>>=s,o[3]=r*l/255),l=a&n,a>>=s,o[2]=r*l,l=a&n,a>>=s,o[1]=r*l,l=a&n,a>>=s,o[0]=r*l,o}const c=2.2},91829:(e,t,s)=>{function n(){return[0,0,0,0]}function r(e,t,s,n){return[e,t,s,n]}function i(e,t,s,n){return[e,t,s,n]}function a(e,t=[0,0,0,0]){const s=Math.min(4,e.length);for(let n=0;n<s;++n)t[n]=e[n];return t}function o(){return r(1,1,1,1)}function l(){return r(1,0,0,0)}function h(){return r(0,1,0,0)}function c(){return r(0,0,1,0)}function u(){return r(0,0,0,1)}s.d(t,{CN:()=>i,Un:()=>d,ci:()=>a,fA:()=>r,uY:()=>f,vt:()=>n});const f=[0,0,0,0],d=o(),y=l(),g=h(),x=c(),p=u();Object.freeze(Object.defineProperty({__proto__:null,ONES:d,UNIT_W:p,UNIT_X:y,UNIT_Y:g,UNIT_Z:x,ZEROS:f,clone:function(e){return[e[0],e[1],e[2],e[3]]},create:n,createView:function(e,t){return new Float64Array(e,t,4)},freeze:i,fromArray:a,fromValues:r,ones:o,unitW:u,unitX:l,unitY:h,unitZ:c,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"}))},34304:(e,t,s)=>{s.d(t,{DF:()=>l,FD:()=>r,Ov:()=>i,ct:()=>h});let n=1e-6;function r(){return n}const i=Math.random,a=Math.PI/180,o=180/Math.PI;function l(e){return e*a}function h(e){return e*o}Object.freeze(Object.defineProperty({__proto__:null,RANDOM:i,equals:function(e,t){return Math.abs(e-t)<=n*Math.max(1,Math.abs(e),Math.abs(t))},getEpsilon:r,setEpsilon:function(e){n=e},toDegree:h,toRadian:l},Symbol.toStringTag,{value:"Module"}))},69397:(e,t,s)=>{s.d(t,{Qf:()=>l,Qh:()=>a,RS:()=>r,ez:()=>u,i5:()=>f,lM:()=>i,qK:()=>c,rq:()=>h});var n=s(34275);const r=16;function i(e){if(!e)return 0;let t=c;for(const s in e)e.hasOwnProperty(s)&&(t+=o(e[s],!1));return t}function a(e){if(!e)return 0;if("number"==typeof e[0])return l(e);if(Array.isArray(e))return function(e){const t=e.length;if(0===t||"number"==typeof e[0])return h(e,8);let s=u;for(let n=0;n<t;n++)s+=o(e[n]);return s}(e);let t=c;for(const s in e)e.hasOwnProperty(s)&&(t+=o(e[s]));return t}function o(e,t=!0){switch(typeof e){case"object":return t?a(e):c;case"string":return function(e){return 32+e.length}(e);case"number":return r;case"boolean":return 4;default:return 8}}function l(...e){return e.reduce(((e,t)=>e+(t?(0,n.iu)(t)?t.byteLength+f:Array.isArray(t)?h(t,r):0:0)),0)}function h(e,t){return u+e.length*t}const c=32,u=16,f=145},11764:(e,t,s)=>{s.r(t),s.d(t,{default:()=>X});var n=s(74887),r=s(89640),i=s(6774),a=s(13195);function o(e){return 746===e||747===e||!(e<4352)&&(e>=12704&&e<=12735||e>=12544&&e<=12591||e>=65072&&e<=65103&&!(e>=65097&&e<=65103)||e>=63744&&e<=64255||e>=13056&&e<=13311||e>=11904&&e<=12031||e>=12736&&e<=12783||e>=12288&&e<=12351&&!(e>=12296&&e<=12305||e>=12308&&e<=12319||12336===e)||e>=13312&&e<=19903||e>=19968&&e<=40959||e>=12800&&e<=13055||e>=12592&&e<=12687||e>=43360&&e<=43391||e>=55216&&e<=55295||e>=4352&&e<=4607||e>=44032&&e<=55215||e>=12352&&e<=12447||e>=12272&&e<=12287||e>=12688&&e<=12703||e>=12032&&e<=12255||e>=12784&&e<=12799||e>=12448&&e<=12543&&12540!==e||e>=65280&&e<=65519&&!(65288===e||65289===e||65293===e||e>=65306&&e<=65310||65339===e||65341===e||65343===e||e>=65371&&e<=65503||65507===e||e>=65512&&e<=65519)||e>=65104&&e<=65135&&!(e>=65112&&e<=65118||e>=65123&&e<=65126)||e>=5120&&e<=5759||e>=6320&&e<=6399||e>=65040&&e<=65055||e>=19904&&e<=19967||e>=40960&&e<=42127||e>=42128&&e<=42191)}function l(e){return!(e<11904)&&(e>=12704&&e<=12735||e>=12544&&e<=12591||e>=65072&&e<=65103||e>=63744&&e<=64255||e>=13056&&e<=13311||e>=11904&&e<=12031||e>=12736&&e<=12783||e>=12288&&e<=12351||e>=13312&&e<=19903||e>=19968&&e<=40959||e>=12800&&e<=13055||e>=65280&&e<=65519||e>=12352&&e<=12447||e>=12272&&e<=12287||e>=12032&&e<=12255||e>=12784&&e<=12799||e>=12448&&e<=12543||e>=65040&&e<=65055||e>=42128&&e<=42191||e>=40960&&e<=42127)}function h(e){switch(e){case 10:case 32:case 38:case 40:case 41:case 43:case 45:case 47:case 173:case 183:case 8203:case 8208:case 8211:case 8231:return!0}return!1}function c(e){switch(e){case 9:case 10:case 11:case 12:case 13:case 32:return!0}return!1}var u=s(18989);const f=24;class d{constructor(e,t,s,n,r,i,a){this._glyphItems=e,this._maxWidth=t,this._lineHeight=s,this._letterSpacing=n,this._hAnchor=r,this._vAnchor=i,this._justify=a}getShaping(e,t,s){const n=this._letterSpacing,r=this._lineHeight,i=this._justify,a=this._maxWidth,u=[];let f=0,d=0;for(const t of e){const e=t.codePointAt(0);if(null==e)continue;const r=s&&o(e);let i;for(const t of this._glyphItems)if(i=t[e],i)break;u.push({codePoint:e,x:f,y:d,vertical:r,glyphMosaicItem:i}),i&&(f+=i.metrics.advance+n)}let y=f;a>0&&(y=f/Math.max(1,Math.ceil(f/a)));const g=e.includes(""),x=[],p=u.length;for(let e=0;e<p-1;e++){const t=u[e].codePoint,s=l(t);if(h(t)||s){let n=0;if(10===t)n-=1e4;else if(s&&g)n+=150;else{40!==t&&65288!==t||(n+=50);const s=u[e+1].codePoint;41!==s&&65289!==s||(n+=50)}x.push(this._buildBreak(e+1,u[e].x,y,x,n,!1))}}const m=this._optimalBreaks(this._buildBreak(p,f,y,x,0,!0));let _=0;const I=t?-r:r;let b=0;for(let e=0;e<m.length;e++){const t=m[e];let s=b;for(;s<t&&c(u[s].codePoint);)u[s].glyphMosaicItem=null,++s;let n=t-1;for(;n>s&&c(u[n].codePoint);)u[n].glyphMosaicItem=null,--n;if(s<=n){const e=u[s].x;for(let t=s;t<=n;t++)u[t].x-=e,u[t].y=d;let t=u[n].x;u[n].glyphMosaicItem&&(t+=u[n].glyphMosaicItem.metrics.advance),_=Math.max(t,_),i&&this._applyJustification(u,s,n)}b=t,d+=I}if(u.length>0){const e=m.length-1,s=(i-this._hAnchor)*_;let n=(-this._vAnchor*(e+1)+.5)*r;t&&e&&(n+=e*r);for(const e of u)e.x+=s,e.y+=n}return u.filter((e=>e.glyphMosaicItem))}static getTextBox(e,t){if(!e.length)return null;let s=1/0,n=1/0,r=0,i=0;for(const a of e){const e=a.glyphMosaicItem.metrics.advance,o=a.x,l=a.y-17,h=o+e,c=l+t;s=Math.min(s,o),r=Math.max(r,h),n=Math.min(n,l),i=Math.max(i,c)}return{x:s,y:n,width:r-s,height:i-n}}static getBox(e){if(!e.length)return null;let t=1/0,s=1/0,n=0,r=0;for(const i of e){const{height:e,left:a,top:o,width:l}=i.glyphMosaicItem.metrics,h=i.x,c=i.y-(e-Math.abs(o)),u=h+l+a,f=c+e;t=Math.min(t,h),n=Math.max(n,u),s=Math.min(s,c),r=Math.max(r,f)}return{x:t,y:s,width:n-t,height:r-s}}static addDecoration(e,t){const s=e.length;if(0===s)return;let n=e[0].x+e[0].glyphMosaicItem.metrics.left,r=e[0].y;for(let i=1;i<s;i++){const s=e[i];if(s.y!==r){const a=e[i-1].x+e[i-1].glyphMosaicItem.metrics.left+e[i-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:n,y:r+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new u.A(4,0,4,8),metrics:{width:a-n,height:8,left:0,top:0,advance:0},page:0,code:0}}),r=s.y,n=s.x+s.glyphMosaicItem.metrics.left}}const i=e[s-1].x+e[s-1].glyphMosaicItem.metrics.left+e[s-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:n,y:r+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new u.A(4,0,4,8),metrics:{width:i-n,height:8,left:0,top:0,advance:0},page:0,code:0}})}_breakScore(e,t,s,n){const r=(e-t)*(e-t);return n?e<t?r/2:2*r:r+Math.abs(s)*s}_buildBreak(e,t,s,n,r,i){let a=null,o=this._breakScore(t,s,r,i);for(const e of n){const n=t-e.x,l=this._breakScore(n,s,r,i)+e.score;l<=o&&(a=e,o=l)}return{index:e,x:t,score:o,previousBreak:a}}_optimalBreaks(e){return e?this._optimalBreaks(e.previousBreak).concat(e.index):[]}_applyJustification(e,t,s){const n=e[s],r=n.vertical?f:n.glyphMosaicItem?n.glyphMosaicItem.metrics.advance:0,i=(n.x+r)*this._justify;for(let n=t;n<=s;n++)e[n].x-=i}}var y=s(4272);const g=.5;class x{constructor(e,t,s=0,n=-1,r=g){this.x=e,this.y=t,this.angle=s,this.segment=n,this.minzoom=r}}class p{constructor(e,t,s,n,r,i=g,o=a.MG){this.anchor=e,this.labelAngle=t,this.glyphAngle=s,this.page=n,this.alternateVerticalGlyph=r,this.minzoom=i,this.maxzoom=o}}class m{constructor(e,t,s,n,r,i,a,o,l,h,c,u){this.tl=e,this.tr=t,this.bl=s,this.br=n,this.mosaicRect=r,this.labelAngle=i,this.minAngle=a,this.maxAngle=o,this.anchor=l,this.minzoom=h,this.maxzoom=c,this.page=u}}class _{constructor(e){this.shapes=e}}class I{getIconPlacement(e,t,s){const n=new i.bR(e.x,e.y),r=s.rotationAlignment===y.I5.MAP,o=s.keepUpright;let l=s.rotate*a.os;r&&(l+=e.angle);const h=new _([]);return s.allowOverlap&&s.ignorePlacement||(h.iconColliders=[]),this._addIconPlacement(h,n,t,s,l),r&&o&&this._addIconPlacement(h,n,t,s,l+a.Jo),h}_addIconPlacement(e,t,s,n,r){const o=s.rasterizationScale,l=s.width/o,h=s.height/o,c=n.offset;let u=c[0],f=c[1];switch(n.anchor){case y.KI.CENTER:u-=l/2,f-=h/2;break;case y.KI.LEFT:f-=h/2;break;case y.KI.RIGHT:u-=l,f-=h/2;break;case y.KI.TOP:u-=l/2;break;case y.KI.BOTTOM:u-=l/2,f-=h;break;case y.KI.TOP_LEFT:break;case y.KI.BOTTOM_LEFT:f-=h;break;case y.KI.TOP_RIGHT:u-=l;break;case y.KI.BOTTOM_RIGHT:u-=l,f-=h}const d=s.rect,x=2/o,p=u-x,_=f-x,I=p+d.width/o,b=_+d.height/o,M=new i.bR(p,_),w=new i.bR(I,b),P=new i.bR(p,b),T=new i.bR(I,_);if(0!==r){const e=Math.cos(r),t=Math.sin(r);M.rotate(e,t),w.rotate(e,t),P.rotate(e,t),T.rotate(e,t)}const A=new m(M,T,P,w,d,r,0,256,t,g,a.MG,0);if(e.shapes.push(A),!n.allowOverlap||!n.ignorePlacement){const s=n.size,i=n.padding,o={xTile:t.x,yTile:t.y,dxPixels:u*s-i,dyPixels:f*s-i,hard:!n.optional,partIndex:0,width:l*s+2*i,height:h*s+2*i,angle:r,minLod:g,maxLod:a.MG};e.iconColliders.push(o)}}getTextPlacement(e,t,s,n){const r=new i.bR(e.x,e.y),o=n.rotate*a.os,l=n.rotationAlignment===y.I5.MAP,h=n.keepUpright,c=n.padding;let u=g;const x=l?e.angle:0,I=e.segment>=0&&l,b=n.allowOverlap&&n.ignorePlacement?null:[],M=[],w=!I;let P=Number.POSITIVE_INFINITY,T=Number.NEGATIVE_INFINITY,A=P,D=T;const k=(I||l)&&h,L=n.size/f;let B=!1;for(const e of t)if(e.vertical){B=!0;break}let V,v=0,R=0;if(!I&&B){const e=d.getTextBox(t,n.lineHeight*f);switch(n.anchor){case y.KI.LEFT:v=e.height/2,R=-e.width/2;break;case y.KI.RIGHT:v=-e.height/2,R=e.width/2;break;case y.KI.TOP:v=e.height/2,R=e.width/2;break;case y.KI.BOTTOM:v=-e.height/2,R=-e.width/2;break;case y.KI.TOP_LEFT:v=e.height;break;case y.KI.BOTTOM_LEFT:R=-e.width;break;case y.KI.TOP_RIGHT:R=e.width;break;case y.KI.BOTTOM_RIGHT:v=-e.height}}v+=n.offset[0]*f,R+=n.offset[1]*f;for(const f of t){const t=f.glyphMosaicItem;if(!t||t.rect.isEmpty)continue;const d=t.rect,y=t.metrics,_=t.page;if(b&&w){if(void 0!==V&&V!==f.y){let t,s,r,i;B?(t=-D+v,s=P+R,r=D-A,i=T-P):(t=P+v,s=A+R,r=T-P,i=D-A);const l={xTile:e.x,yTile:e.y,dxPixels:t*L-c,dyPixels:s*L-c,hard:!n.optional,partIndex:1,width:r*L+2*c,height:i*L+2*c,angle:o,minLod:g,maxLod:a.MG};b.push(l),P=Number.POSITIVE_INFINITY,T=Number.NEGATIVE_INFINITY,A=P,D=T}V=f.y}const S=[];if(I){const n=.5*t.metrics.width,r=(f.x+y.left-4+n)*L*8;if(u=this._placeGlyph(e,u,r,s,e.segment,1,f.vertical,_,S),h&&(u=this._placeGlyph(e,u,r,s,e.segment,-1,f.vertical,_,S)),u>=2)break}else S.push(new p(r,x,x,_,!1)),l&&h&&S.push(new p(r,x+a.Jo,x+a.Jo,_,!1));const C=f.x+y.left,O=f.y-17-y.top,E=C+y.width,F=O+y.height;let z,N,U,G,K,q,H,W;if(!I&&B)if(f.vertical){const e=(C+E)/2-y.height/2,t=(O+F)/2+y.width/2;z=new i.bR(-t-4+v,e-4+R),N=new i.bR(z.x+d.width,z.y+d.height),U=new i.bR(z.x,N.y),G=new i.bR(N.x,z.y)}else z=new i.bR(4-O+v,C-4+R),N=new i.bR(z.x-d.height,z.y+d.width),U=new i.bR(N.x,z.y),G=new i.bR(z.x,N.y);else z=new i.bR(C-4+v,O-4+R),N=new i.bR(z.x+d.width,z.y+d.height),U=new i.bR(z.x,N.y),G=new i.bR(N.x,z.y);for(const t of S){let s,r,a,l;if(t.alternateVerticalGlyph){if(!K){const e=(O+F)/2+R;K=new i.bR((C+E)/2+v-y.height/2-4,e+y.width/2+4),q=new i.bR(K.x+d.height,K.y-d.width),H=new i.bR(q.x,K.y),W=new i.bR(K.x,q.y)}s=K,r=H,a=W,l=q}else s=z,r=U,a=G,l=N;const h=O,u=F,g=t.glyphAngle+o;if(0!==g){const e=Math.cos(g),t=Math.sin(g);s=s.clone(),r=r?.clone(),a=a?.clone(),l=l?.clone(),s.rotate(e,t),l?.rotate(e,t),r?.rotate(e,t),a?.rotate(e,t)}let x=0,p=256;if(I&&B?f.vertical?t.alternateVerticalGlyph?(x=32,p=96):(x=224,p=32):(x=224,p=96):(x=192,p=64),M.push(new m(s,a,r,l,d,t.labelAngle,x,p,t.anchor,t.minzoom,t.maxzoom,t.page)),b&&(!k||this._legible(t.labelAngle)))if(w)C<P&&(P=C),h<A&&(A=h),E>T&&(T=E),u>D&&(D=u);else if(t.minzoom<2){const s={xTile:e.x,yTile:e.y,dxPixels:(C+v)*L-c,dyPixels:(h+v)*L-c,hard:!n.optional,partIndex:1,width:(E-C)*L+2*c,height:(u-h)*L+2*c,angle:g,minLod:t.minzoom,maxLod:t.maxzoom};b.push(s)}}}if(u>=2)return null;if(b&&w){let t,s,r,i;B?(t=-D+v,s=P+R,r=D-A,i=T-P):(t=P+v,s=A+R,r=T-P,i=D-A);const l={xTile:e.x,yTile:e.y,dxPixels:t*L-c,dyPixels:s*L-c,hard:!n.optional,partIndex:1,width:r*L+2*c,height:i*L+2*c,angle:o,minLod:g,maxLod:a.MG};b.push(l)}const S=new _(M);return b&&b.length>0&&(S.textColliders=b),S}_legible(e){const t=(0,a.z0)(e);return t<65||t>=193}_placeGlyph(e,t,s,n,r,o,l,h,c){let u=o;const f=u<0?(0,a.Wh)(e.angle+a.Jo,a.pJ):e.angle;let d=0;s<0&&(u*=-1,s*=-1,d=a.Jo),u>0&&++r;let y=new i.bR(e.x,e.y),g=n[r],x=a.MG;if(n.length<=r)return x;for(;;){const e=g.x-y.x,i=g.y-y.y,o=Math.sqrt(e*e+i*i),m=Math.max(s/o,t),_=e/o,I=i/o,b=(0,a.Wh)(Math.atan2(I,_)+d,a.pJ);if(c.push(new p(y,f,b,h,!1,m,x)),l&&c.push(new p(y,f,b,h,!0,m,x)),m<=t)return m;y=g.clone();do{if(r+=u,n.length<=r||r<0)return m;g=n[r]}while(y.isEqual(g));let M=g.x-y.x,w=g.y-y.y;const P=Math.sqrt(M*M+w*w);M*=o/P,w*=o/P,y.x-=M,y.y-=w,x=m}}}var b,M,w=s(51624),P=s(15585);(M=b||(b={}))[M.moveTo=1]="moveTo",M[M.lineTo=2]="lineTo",M[M.close=7]="close";class T{constructor(e,t,s=0){this.values={},this._geometry=void 0,this._pbfGeometry=null,this.featureIndex=s;const n=t.keys,r=t.values,i=e.asUnsafe();for(;i.next();)switch(i.tag()){case 1:this.id=i.getUInt64();break;case 2:{const e=i.getMessage().asUnsafe(),t=this.values;for(;!e.empty();){const s=e.getUInt32(),i=e.getUInt32();t[n[s]]=r[i]}e.release();break}case 3:this.type=i.getUInt32();break;case 4:this._pbfGeometry=i.getMessage();break;default:i.skip()}}getGeometry(e){if(void 0!==this._geometry)return this._geometry;if(!this._pbfGeometry)return null;const t=this._pbfGeometry.asUnsafe();let s,n;this._pbfGeometry=null,e?e.reset(this.type):s=[];let r,a=b.moveTo,o=0,l=0,h=0;for(;!t.empty();){if(0===o){const e=t.getUInt32();a=7&e,o=e>>3}switch(o--,a){case b.moveTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.moveTo(l,h):s&&(n&&s.push(n),n=[],n.push(new i.bR(l,h)));break;case b.lineTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.lineTo(l,h):n&&n.push(new i.bR(l,h));break;case b.close:e?e.close():n&&!n[0].equals(l,h)&&n.push(n[0].clone());break;default:throw t.release(),new Error("Invalid path operation")}}return e?r=e.result():s&&(n&&s.push(n),r=s),t.release(),this._geometry=r,r}}var A=s(80081);class D extends A.A{constructor(){super(12)}add(e,t,s){const n=this.array;n.push(e),n.push(t),n.push(s)}}A.A;class k{constructor(e){this.extent=4096,this.keys=[],this.values=[],this._pbfLayer=e.clone();const t=e.asUnsafe();for(;t.next();)switch(t.tag()){case 1:this.name=t.getString();break;case 3:this.keys.push(t.getString());break;case 4:this.values.push(t.processMessage(k._parseValue));break;case 5:this.extent=t.getUInt32();break;default:t.skip()}}getData(){return this._pbfLayer}static _parseValue(e){for(;e.next();)switch(e.tag()){case 1:return e.getString();case 2:return e.getFloat();case 3:return e.getDouble();case 4:return e.getInt64();case 5:return e.getUInt64();case 6:return e.getSInt64();case 7:return e.getBool();default:e.skip()}return null}}class L extends A.A{constructor(e){super(e)}add(e,t,s,n,r,i,a,o,l,h,c,u){const f=this.array;let d=A.A.i1616to32(e,t);f.push(d);const y=31;d=A.A.i8888to32(Math.round(y*s),Math.round(y*n),Math.round(y*r),Math.round(y*i)),f.push(d),d=A.A.i8888to32(Math.round(y*a),Math.round(y*o),Math.round(y*l),Math.round(y*h)),f.push(d),d=A.A.i1616to32(c,0),f.push(d),u&&f.push(...u)}}class B extends A.A{constructor(e){super(e)}add(e,t,s){const n=this.array;n.push(A.A.i1616to32(e,t)),s&&n.push(...s)}}class V extends A.A{constructor(e){super(e)}add(e,t,s,n,r,i,a){const o=this.array,l=this.index;let h=A.A.i1616to32(e,t);return o.push(h),h=A.A.i8888to32(Math.round(15*s),Math.round(15*n),r,i),o.push(h),a&&o.push(...a),l}}class v extends A.A{constructor(e){super(e)}add(e,t,s,n,r,i,o,l,h,c,u,f){const d=this.array;let y=A.A.i1616to32(e,t);d.push(y),y=A.A.i1616to32(Math.round(8*s),Math.round(8*n)),d.push(y),y=A.A.i8888to32(r/4,i/4,l,h),d.push(y),y=A.A.i8888to32(0,(0,a.z0)(o),10*c,Math.min(10*u,255)),d.push(y),f&&d.push(...f)}}class R extends A.A{constructor(e){super(e)}add(e,t,s,n,r){const i=this.array,a=A.A.i1616to32(2*e+s,2*t+n);i.push(a),r&&i.push(...r)}}class S{constructor(e,t,s){this.layerExtent=4096,this._features=[],this.layer=e,this.zoom=t,this._spriteInfo=s,this._filter=e.getFeatureFilter()}pushFeature(e){this._filter&&!this._filter.filter(e,this.zoom)||this._features.push(e)}hasFeatures(){return this._features.length>0}getResources(e,t,s){}}class C extends S{constructor(e,t,s,n,i){super(e,t,s),this.type=r.NP.CIRCLE,this._circleVertexBuffer=n,this._circleIndexBuffer=i}get circleIndexStart(){return this._circleIndexStart}get circleIndexCount(){return this._circleIndexCount}processFeatures(e){const t=this._circleVertexBuffer,s=this._circleIndexBuffer;this._circleIndexStart=3*s.index,this._circleIndexCount=0;const n=this.layer,r=this.zoom;e&&e.setExtent(this.layerExtent);for(const i of this._features){const a=i.getGeometry(e);if(!a)continue;const o=n.circleMaterial.encodeAttributes(i,r,n);for(const e of a)if(e)for(const n of e){const e=t.index;t.add(n.x,n.y,0,0,o),t.add(n.x,n.y,0,1,o),t.add(n.x,n.y,1,0,o),t.add(n.x,n.y,1,1,o),s.add(e,e+1,e+2),s.add(e+1,e+2,e+3),this._circleIndexCount+=6}}}serialize(){let e=6;e+=this.layerUIDs.length,e+=this._circleVertexBuffer.array.length,e+=this._circleIndexBuffer.array.length;const t=new Uint32Array(e),s=new Int32Array(t.buffer);let n=0;t[n++]=this.type,t[n++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[n++]=this.layerUIDs[e];t[n++]=this._circleIndexStart,t[n++]=this._circleIndexCount,t[n++]=this._circleVertexBuffer.array.length;for(let e=0;e<this._circleVertexBuffer.array.length;e++)s[n++]=this._circleVertexBuffer.array[e];t[n++]=this._circleIndexBuffer.array.length;for(let e=0;e<this._circleIndexBuffer.array.length;e++)t[n++]=this._circleIndexBuffer.array[e];return t.buffer}}var O=s(98291),E=s(83349);class F extends S{constructor(e,t,s,n,i,a,o){super(e,t,s),this.type=r.NP.FILL,this._patternMap=new Map,this._fillVertexBuffer=n,this._fillIndexBuffer=i,this._outlineVertexBuffer=a,this._outlineIndexBuffer=o}get fillIndexStart(){return this._fillIndexStart}get fillIndexCount(){return this._fillIndexCount}get outlineIndexStart(){return this._outlineIndexStart}get outlineIndexCount(){return this._outlineIndexCount}getResources(e,t,s){const n=this.layer,r=this.zoom,i=n.getPaintProperty("fill-pattern");if(i)if(i.isDataDriven)for(const e of this._features)t(i.getValue(r,e),!0);else t(i.getValue(r),!0)}processFeatures(e){this._fillIndexStart=3*this._fillIndexBuffer.index,this._fillIndexCount=0,this._outlineIndexStart=3*this._outlineIndexBuffer.index,this._outlineIndexCount=0;const t=this.layer,s=this.zoom,{fillMaterial:n,outlineMaterial:r,hasDataDrivenFill:i,hasDataDrivenOutline:a}=t;e&&e.setExtent(this.layerExtent);const o=t.getPaintProperty("fill-pattern"),l=o?.isDataDriven;let h=!o&&t.getPaintValue("fill-antialias",s);if(t.outlineUsesFillColor){if(h&&!t.hasDataDrivenOpacity){const e=t.getPaintValue("fill-opacity",s),n=t.getPaintValue("fill-opacity",s+1);e<1&&n<1&&(h=!1)}if(h&&!t.hasDataDrivenColor){const e=t.getPaintValue("fill-color",s),n=t.getPaintValue("fill-color",s+1);e[3]<1&&n[3]<1&&(h=!1)}}const c=this._features,u=e?.validateTessellation;if(l){const i=[];for(const l of c){const c=o.getValue(s,l),f=this._spriteInfo[c];if(!f?.rect)continue;const d=n.encodeAttributes(l,s,t,f),y=h&&a?r.encodeAttributes(l,s,t):[],g=l.getGeometry(e);i.push({ddFillAttributes:d,ddOutlineAttributes:y,page:f.page,geometry:g}),i.sort(((e,t)=>e.page-t.page));for(const{ddFillAttributes:e,ddOutlineAttributes:s,page:n,geometry:r}of i)this._processFeature(r,h,t.outlineUsesFillColor,e,s,u,n)}}else for(const o of c){const l=i?n.encodeAttributes(o,s,t):null,c=h&&a?r.encodeAttributes(o,s,t):null,f=o.getGeometry(e);this._processFeature(f,h,t.outlineUsesFillColor,l,c,u)}}serialize(){let e=10;e+=this.layerUIDs.length,e+=this._fillVertexBuffer.array.length,e+=this._fillIndexBuffer.array.length,e+=this._outlineVertexBuffer.array.length,e+=this._outlineIndexBuffer.array.length,e+=3*this._patternMap.size+1;const t=new Uint32Array(e),s=new Int32Array(t.buffer);let n=0;t[n++]=this.type,t[n++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[n++]=this.layerUIDs[e];t[n++]=this._fillIndexStart,t[n++]=this._fillIndexCount,t[n++]=this._outlineIndexStart,t[n++]=this._outlineIndexCount;const r=this._patternMap,i=r.size;if(t[n++]=i,i>0)for(const[e,[s,i]]of r)t[n++]=e,t[n++]=s,t[n++]=i;t[n++]=this._fillVertexBuffer.array.length;for(let e=0;e<this._fillVertexBuffer.array.length;e++)s[n++]=this._fillVertexBuffer.array[e];t[n++]=this._fillIndexBuffer.array.length;for(let e=0;e<this._fillIndexBuffer.array.length;e++)t[n++]=this._fillIndexBuffer.array[e];t[n++]=this._outlineVertexBuffer.array.length;for(let e=0;e<this._outlineVertexBuffer.array.length;e++)s[n++]=this._outlineVertexBuffer.array[e];t[n++]=this._outlineIndexBuffer.array.length;for(let e=0;e<this._outlineIndexBuffer.array.length;e++)t[n++]=this._outlineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s,n,r,i,a){if(!e)return;const o=e.length,l=!r||0===r.length;if(t&&(!s||l))for(let t=0;t<o;t++)this._processOutline(e[t],r);let h;for(let t=0;t<o;t++){const s=F._area(e[t]);s>32?(void 0!==h&&this._processFill(e,h,n,i,a),h=[t]):s<-32&&void 0!==h&&h.push(t)}void 0!==h&&this._processFill(e,h,n,i,a)}_processOutline(e,t){const s=this._outlineVertexBuffer,n=this._outlineIndexBuffer,r=n.index;let a,o,l;const h=new i.bR(0,0),c=new i.bR(0,0),u=new i.bR(0,0);let f=-1,d=-1,y=-1,g=-1,x=-1,p=!1,m=e.length;if(m<2)return;const _=e[0];let I=e[m-1];for(;m&&I.isEqual(_);)--m,I=e[m-1];if(!(m-0<2)){for(let r=0;r<m;++r){0===r?(a=e[m-1],o=e[0],l=e[1],h.assignSub(o,a),h.normalize(),h.rightPerpendicular()):(a=o,o=l,l=r!==m-1?e[r+1]:e[0],h.assign(c));const i=this._isClipEdge(a,o);-1===g&&(p=i),c.assignSub(l,o),c.normalize(),c.rightPerpendicular();const _=h.x*c.y-h.y*c.x;u.assignAdd(h,c),u.normalize();const I=-u.x*-h.x+-u.y*-h.y;let b=Math.abs(0!==I?1/I:1);b>8&&(b=8),_>=0?(y=s.add(o.x,o.y,h.x,h.y,0,1,t),-1===g&&(g=y),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),d=s.add(o.x,o.y,b*-u.x,b*-u.y,0,-1,t),-1===x&&(x=d),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),f=d,d=y,y=s.add(o.x,o.y,u.x,u.y,0,1,t),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),d=s.add(o.x,o.y,c.x,c.y,0,1,t),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y)):(y=s.add(o.x,o.y,b*u.x,b*u.y,0,1,t),-1===g&&(g=y),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),d=s.add(o.x,o.y,-h.x,-h.y,0,-1,t),-1===x&&(x=d),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),f=d,d=y,y=s.add(o.x,o.y,-u.x,-u.y,0,-1,t),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y),f=s.add(o.x,o.y,-c.x,-c.y,0,-1,t),f>=0&&d>=0&&y>=0&&!i&&n.add(f,d,y))}f>=0&&d>=0&&g>=0&&!p&&n.add(f,d,g),f>=0&&g>=0&&x>=0&&!p&&n.add(f,x,g),this._outlineIndexCount+=3*(n.index-r)}}_processFill(e,t,s,n,r){let i;t.length>1&&(i=[]);let a=0;for(const s of t)0!==a&&i.push(a),a+=e[s].length;const o=2*a,l=O.A.acquire();for(const s of t){const t=e[s],n=t.length;for(let e=0;e<n;++e)l.push(t[e].x,t[e].y)}const h=(0,E.e)(l,i,2);if(E.e.deviation(l,i,2,h)>0){const n=t.map((t=>e[t].length)),{buffer:i,vertexCount:a}=(0,P.l)(l,n);if(a>0){const e=this._fillVertexBuffer.index;for(let e=0;e<a;e++)this._fillVertexBuffer.add(i[2*e],i[2*e+1],s);for(let t=0;t<a;t+=3){const s=e+t;this._fillIndexBuffer.add(s,s+1,s+2)}if(void 0!==r){const e=this._patternMap,t=e.get(r);t?t[1]+=a:e.set(r,[this._fillIndexStart+this._fillIndexCount,a])}this._fillIndexCount+=a}}else{const e=h.length;if(e>0){const t=this._fillVertexBuffer.index;let n=0;for(;n<o;)this._fillVertexBuffer.add(l[n++],l[n++],s);let i=0;for(;i<e;)this._fillIndexBuffer.add(t+h[i++],t+h[i++],t+h[i++]);if(void 0!==r){const t=this._patternMap,s=t.get(r);s?s[1]+=e:t.set(r,[this._fillIndexStart+this._fillIndexCount,e])}this._fillIndexCount+=e}}O.A.release(l)}_isClipEdge(e,t){return e.x===t.x?e.x<=-64||e.x>=4160:e.y===t.y&&(e.y<=-64||e.y>=4160)}static _area(e){let t=0;const s=e.length-1;for(let n=0;n<s;n++)t+=(e[n].x-e[n+1].x)*(e[n].y+e[n+1].y);return t+=(e[s].x-e[0].x)*(e[s].y+e[0].y),.5*t}}var z=s(83773);class N extends S{constructor(e,t,s,n,i){super(e,t,s),this.type=r.NP.LINE,this._tessellationOptions={pixelCoordRatio:8,halfWidth:0,offset:0},this._patternMap=new Map,this.tessellationProperties={_lineVertexBuffer:null,_lineIndexBuffer:null,_ddValues:null},this.tessellationProperties._lineVertexBuffer=n,this.tessellationProperties._lineIndexBuffer=i,this._lineTessellator=new z.i(U(this.tessellationProperties),G(this.tessellationProperties),e.canUseThinTessellation)}get lineIndexStart(){return this._lineIndexStart}get lineIndexCount(){return this._lineIndexCount}getResources(e,t,s){const n=this.layer,r=this.zoom,i=n.getPaintProperty("line-pattern"),a=n.getPaintProperty("line-dasharray"),o=n.getLayoutProperty("line-cap");if(!i&&!a)return;const l=o?.getValue(r)||0,h=o?.isDataDriven,c=i?.isDataDriven,u=a?.isDataDriven;if(c||u)for(const e of this._features)t(c?i.getValue(r,e):this._getDashArrayKey(e,r,n,a,h,o,l));else if(i)t(i.getValue(r));else if(a){const e=a.getValue(r);t(n.getDashKey(e,l))}}processFeatures(e){this._lineIndexStart=3*this.tessellationProperties._lineIndexBuffer.index,this._lineIndexCount=0;const t=this.layer,s=this.zoom,n=this._features,r=this._tessellationOptions,{hasDataDrivenLine:i,lineMaterial:a}=t;e&&e.setExtent(this.layerExtent);const o=t.getPaintProperty("line-pattern"),l=t.getPaintProperty("line-dasharray"),h=o?.isDataDriven,c=l?.isDataDriven;let u;u=t.getLayoutProperty("line-cap");const f=u?.isDataDriven?u:null,d=f?null:t.getLayoutValue("line-cap",s),y=d||0,g=!!f;u=t.getLayoutProperty("line-join");const x=u?.isDataDriven?u:null,p=x?null:t.getLayoutValue("line-join",s);u=t.getLayoutProperty("line-miter-limit");const m=u?.isDataDriven?u:null,_=m?null:t.getLayoutValue("line-miter-limit",s);u=t.getLayoutProperty("line-round-limit");const I=u?.isDataDriven?u:null,b=I?null:t.getLayoutValue("line-round-limit",s);u=t.getPaintProperty("line-width");const M=u?.isDataDriven?u:null,w=M?null:t.getPaintValue("line-width",s);u=t.getPaintProperty("line-offset");const P=u?.isDataDriven?u:null,T=P?null:t.getPaintValue("line-offset",s);if(h||c){const i=[];for(const r of n){const n=h?o.getValue(s,r):this._getDashArrayKey(r,s,t,l,g,f,y),c=this._spriteInfo[n];if(!c?.rect)continue;const u=a.encodeAttributes(r,s,t,c),A=r.getGeometry(e);i.push({ddAttributes:u,page:c.page,cap:f?f.getValue(s,r):d,join:x?x.getValue(s,r):p,miterLimit:m?m.getValue(s,r):_,roundLimit:I?I.getValue(s,r):b,halfWidth:.5*(M?M.getValue(s,r):w),offset:P?P.getValue(s,r):T,geometry:A})}i.sort(((e,t)=>e.page-t.page)),r.textured=!0;for(const{ddAttributes:e,page:t,cap:s,join:n,miterLimit:a,roundLimit:o,halfWidth:l,offset:h,geometry:c}of i)r.capType=s,r.joinType=n,r.miterLimit=a,r.roundLimit=o,r.halfWidth=l,r.offset=h,this._processFeature(c,e,t)}else{if(o){const e=o.getValue(s),t=this._spriteInfo[e];if(!t?.rect)return}r.textured=!(!o&&!l),r.capType=d,r.joinType=p,r.miterLimit=_,r.roundLimit=b,r.halfWidth=.5*w,r.offset=T;for(const o of n){const n=i?a.encodeAttributes(o,s,t):null;f&&(r.capType=f.getValue(s,o)),x&&(r.joinType=x.getValue(s,o)),m&&(r.miterLimit=m.getValue(s,o)),I&&(r.roundLimit=I.getValue(s,o)),M&&(r.halfWidth=.5*M.getValue(s,o)),P&&(r.offset=P.getValue(s,o));const l=o.getGeometry(e);this._processFeature(l,n)}}}serialize(){let e=6;e+=this.layerUIDs.length,e+=this.tessellationProperties._lineVertexBuffer.array.length,e+=this.tessellationProperties._lineIndexBuffer.array.length,e+=3*this._patternMap.size+1;const t=new Uint32Array(e),s=new Int32Array(t.buffer);let n=0;t[n++]=this.type,t[n++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[n++]=this.layerUIDs[e];t[n++]=this._lineIndexStart,t[n++]=this._lineIndexCount;const r=this._patternMap,i=r.size;if(t[n++]=i,i>0)for(const[e,[s,i]]of r)t[n++]=e,t[n++]=s,t[n++]=i;t[n++]=this.tessellationProperties._lineVertexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineVertexBuffer.array.length;e++)s[n++]=this.tessellationProperties._lineVertexBuffer.array[e];t[n++]=this.tessellationProperties._lineIndexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineIndexBuffer.array.length;e++)t[n++]=this.tessellationProperties._lineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s){if(!e)return;const n=e.length;for(let r=0;r<n;r++)this._processGeometry(e[r],t,s)}_processGeometry(e,t,s){if(e.length<2)return;let n,r,i=e[0],a=1;for(;a<e.length;)n=e[a].x-i.x,r=e[a].y-i.y,n*n+r*r<1e-6?e.splice(a,1):(i=e[a],++a);if(e.length<2)return;const o=this.tessellationProperties._lineIndexBuffer,l=3*o.index;this._tessellationOptions.initialDistance=0,this._tessellationOptions.wrapDistance=65535,this.tessellationProperties._ddValues=t,this._lineTessellator.tessellate(e,this._tessellationOptions);const h=3*o.index-l;if(void 0!==s){const e=this._patternMap,t=e.get(s);t?t[1]+=h:e.set(s,[l+this._lineIndexCount,h])}this._lineIndexCount+=h}_getDashArrayKey(e,t,s,n,r,i,a){const o=r?i.getValue(t,e):a,l=n.getValue(t,e);return s.getDashKey(l,o)}}const U=e=>(t,s,n,r,i,a,o,l,h,c,u)=>(e._lineVertexBuffer.add(t,s,o,l,n,r,i,a,h,c,u,e._ddValues),e._lineVertexBuffer.index-1),G=e=>(t,s,n)=>{e._lineIndexBuffer.add(t,s,n)};var K,q=s(32488),H=s(97768),W=s(799),j=s(3057);function Y(e,t){return e.iconMosaicItem&&t.iconMosaicItem?e.iconMosaicItem.page===t.iconMosaicItem.page?0:e.iconMosaicItem.page-t.iconMosaicItem.page:e.iconMosaicItem&&!t.iconMosaicItem?1:!e.iconMosaicItem&&t.iconMosaicItem?-1:0}class J extends S{constructor(e,t,s,n,i,a,o,l,h){super(t,s,h.getSpriteItems()),this.type=r.NP.SYMBOL,this._markerMap=new Map,this._glyphMap=new Map,this._glyphBufferDataStorage=new Map,this._isIconSDF=!1,this._sourceTileKey=e,this._iconVertexBuffer=n,this._iconIndexBuffer=i,this._textVertexBuffer=a,this._textIndexBuffer=o,this._placementEngine=l,this._workerTileHandler=h}get markerPageMap(){return this._markerMap}get glyphsPageMap(){return this._glyphMap}get symbolInstances(){return this._symbolInstances}getResources(e,t,s){const n=this.layer,r=this.zoom;e&&e.setExtent(this.layerExtent);const i=n.getLayoutProperty("icon-image"),a=n.getLayoutProperty("text-field");let o=n.getLayoutProperty("text-transform"),l=n.getLayoutProperty("text-font");const h=[];let c,u,f,d;i&&!i.isDataDriven&&(c=i.getValue(r)),a&&!a.isDataDriven&&(u=a.getValue(r)),o&&o.isDataDriven||(f=n.getLayoutValue("text-transform",r),o=null),l&&l.isDataDriven||(d=n.getLayoutValue("text-font",r),l=null);for(const g of this._features){const x=g.getGeometry(e);if(!x||0===x.length)continue;let p,m;i&&(p=i.isDataDriven?i.getValue(r,g):this._replaceKeys(c,g.values),p&&t(p));let _=!1;if(a&&(m=a.isDataDriven?a.getValue(r,g):this._replaceKeys(u,g.values),m)){switch(m=m.replaceAll("\\n","\n"),o&&(f=o.getValue(r,g)),f){case y.Ms.LOWERCASE:m=m.toLowerCase();break;case y.Ms.UPPERCASE:m=m.toUpperCase()}if(J._bidiEngine.hasBidiChar(m)){let e;e="rtl"===J._bidiEngine.checkContextual(m)?"IDNNN":"ICNNN",m=J._bidiEngine.bidiTransform(m,e,"VLYSN"),_=!0}if(m.length>0){l&&(d=l.getValue(r,g));for(const e of d){let t=s[e];t||(t=s[e]=new Set);for(const e of m){const s=e.codePointAt(0);null!=s&&t.add(s)}}}}if(!p&&!m)continue;const I=n.getLayoutValue("symbol-sort-key",r,g),b={feature:g,sprite:p,label:m,rtl:_,geometry:x,hash:(m?(0,W.Wm)(m):0)^(p?(0,W.Wm)(p):0),priority:I,textFont:d};h.push(b)}this._symbolFeatures=h}processFeatures(e){e&&e.setExtent(this.layerExtent);const t=this.layer,s=this.zoom,n=t.getLayoutValue("symbol-placement",s),r=n!==y.kt.POINT,o=8*t.getLayoutValue("symbol-spacing",s),l=t.getLayoutProperty("icon-image"),h=t.getLayoutProperty("text-field"),c=l?new j.aR(t,s,r):null,u=h?new j.uU(t,s,r):null,g=this._workerTileHandler;let p;l&&(p=g.getSpriteItems()),this._iconIndexStart=3*this._iconIndexBuffer.index,this._textIndexStart=3*this._textIndexBuffer.index,this._iconIndexCount=0,this._textIndexCount=0,this._markerMap.clear(),this._glyphMap.clear();const m=[];let _=1;u?.size&&(_=u.size/f);const I=u?u.maxAngle*a.os:0,b=u?8*u.size:0;for(const e of this._symbolFeatures){let t,a;c&&p&&e.sprite&&(t=p[e.sprite],t&&t.sdf&&(this._isIconSDF=!0)),t&&c.update(s,e.feature);let l=0;const h=e.label;if(h){(0,H.Lw)(u),u.update(s,e.feature);const t=r&&u.rotationAlignment===y.I5.MAP?u.keepUpright:u.writingMode&&u.writingMode.includes(y.v9.VERTICAL);let n=.5;switch(u.anchor){case y.KI.TOP_LEFT:case y.KI.LEFT:case y.KI.BOTTOM_LEFT:n=0;break;case y.KI.TOP_RIGHT:case y.KI.RIGHT:case y.KI.BOTTOM_RIGHT:n=1}let i=.5;switch(u.anchor){case y.KI.TOP_LEFT:case y.KI.TOP:case y.KI.TOP_RIGHT:i=0;break;case y.KI.BOTTOM_LEFT:case y.KI.BOTTOM:case y.KI.BOTTOM_RIGHT:i=1}let o=.5;switch(u.justify){case y.O6.AUTO:o=n;break;case y.O6.LEFT:o=0;break;case y.O6.RIGHT:o=1}const c=u.letterSpacing*f,x=r?0:u.maxWidth*f,p=u.lineHeight*f,m=e.textFont.map((e=>g.getGlyphItems(e)));if(a=new d(m,x,p,c,n,i,o).getShaping(h,e.rtl,t),a&&a.length>0){let e=1e30,t=-1e30;for(const s of a)e=Math.min(e,s.x),t=Math.max(t,s.x);l=(t-e+48)*_*8}}for(let s of e.geometry){const h=[];if(n===y.kt.LINE){if(a?.length&&u?.size){const e=8*u.size*(2+Math.min(2,4*Math.abs(u.offset[1])));s=J._smoothVertices(s,e)}J._pushAnchors(h,s,o,l)}else n===y.kt.LINE_CENTER?J._pushCenterAnchor(h,s):e.feature.type===i.dC.Polygon?J._pushCentroid(h,s):h.push(new x(s[0].x,s[0].y));for(const n of h){if(n.x<0||n.x>4096||n.y<0||n.y>4096)continue;if(r&&l>0&&u?.rotationAlignment===y.I5.MAP&&!J._honorsTextMaxAngle(s,n,l,I,b))continue;const i={shaping:a,line:s,iconMosaicItem:t,anchor:n,symbolFeature:e,textColliders:[],iconColliders:[],textVertexRanges:[],iconVertexRanges:[]};m.push(i),this._processFeature(i,c,u)}}}m.sort(Y),this._addPlacedGlyphs(),this._symbolInstances=m}serialize(){let e=14;e+=this.layerUIDs.length,e+=3*this.markerPageMap.size,e+=3*this.glyphsPageMap.size,e+=J._symbolsSerializationLength(this._symbolInstances),e+=this._iconVertexBuffer.array.length,e+=this._iconIndexBuffer.array.length,e+=this._textVertexBuffer.array.length,e+=this._textIndexBuffer.array.length;const t=new Uint32Array(e),s=new Int32Array(t.buffer),n=new Float32Array(t.buffer),[r,i,a]=this._sourceTileKey.split("/");let o=0;t[o++]=this.type,t[o++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[o++]=this.layerUIDs[e];t[o++]=this._isIconSDF?1:0,t[o++]=parseFloat(r),t[o++]=parseFloat(i),t[o++]=parseFloat(a),t[o++]=this.markerPageMap.size;for(const[e,[s,n]]of this.markerPageMap)t[o++]=e,t[o++]=s,t[o++]=n;t[o++]=this.glyphsPageMap.size;for(const[e,[s,n]]of this.glyphsPageMap)t[o++]=e,t[o++]=s,t[o++]=n;t[o++]=this._iconVertexBuffer.index/4,t[o++]=this._textVertexBuffer.index/4,o=J.serializeSymbols(t,s,n,o,this._symbolInstances),t[o++]=this._iconVertexBuffer.array.length;for(let e=0;e<this._iconVertexBuffer.array.length;e++)s[o++]=this._iconVertexBuffer.array[e];t[o++]=this._iconIndexBuffer.array.length;for(let e=0;e<this._iconIndexBuffer.array.length;e++)t[o++]=this._iconIndexBuffer.array[e];t[o++]=this._textVertexBuffer.array.length;for(let e=0;e<this._textVertexBuffer.array.length;e++)s[o++]=this._textVertexBuffer.array[e];t[o++]=this._textIndexBuffer.array.length;for(let e=0;e<this._textIndexBuffer.array.length;e++)t[o++]=this._textIndexBuffer.array[e];return t.buffer}static _symbolsSerializationLength(e){let t=0;t+=1;for(const s of e||[]){t+=5,t+=1;for(const e of s.textColliders)t+=10;for(const e of s.iconColliders)t+=10;t+=1,t+=2*s.textVertexRanges.length,t+=1,t+=2*s.iconVertexRanges.length}return t}static serializeSymbols(e,t,s,n,r){r=r||[],t[n++]=r.length;for(const e of r){t[n++]=e.anchor.x,t[n++]=e.anchor.y,t[n++]=e.symbolFeature.hash,t[n++]=e.symbolFeature.priority,t[n++]=e.symbolFeature.feature.featureIndex,t[n++]=e.textColliders.length+e.iconColliders.length;for(const r of e.textColliders)t[n++]=r.xTile,t[n++]=r.yTile,t[n++]=r.dxPixels,t[n++]=r.dyPixels,t[n++]=r.hard?1:0,t[n++]=r.partIndex,s[n++]=r.minLod,s[n++]=r.maxLod,t[n++]=r.width,t[n++]=r.height;for(const r of e.iconColliders)t[n++]=r.xTile,t[n++]=r.yTile,t[n++]=r.dxPixels,t[n++]=r.dyPixels,t[n++]=r.hard?1:0,t[n++]=r.partIndex,s[n++]=r.minLod,s[n++]=r.maxLod,t[n++]=r.width,t[n++]=r.height;t[n++]=e.textVertexRanges.length;for(const[s,r]of e.textVertexRanges)t[n++]=s,t[n++]=r;t[n++]=e.iconVertexRanges.length;for(const[s,r]of e.iconVertexRanges)t[n++]=s,t[n++]=r}return n}_replaceKeys(e,t){return e.replaceAll(/{([^{}]+)}/g,((e,s)=>s in t?t[s]:""))}_processFeature(e,t,s){const{line:n,iconMosaicItem:r,shaping:i,anchor:o}=e,l=this.zoom,h=this.layer,c=!!r;let u=!0;c&&(u=t?.optional||!r);const f=i&&i.length>0,d=!f||s?.optional;let g,x;if(c&&(g=this._placementEngine.getIconPlacement(o,r,t)),(g||u)&&(f&&(x=this._placementEngine.getTextPlacement(o,i,n,s)),x||d)){if(g&&x||(d||u?d||x?u||g||(x=null):g=null:(g=null,x=null)),x){const t=h.hasDataDrivenText?h.textMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._storePlacedGlyphs(e,x.shapes,l,s.rotationAlignment,t),x.textColliders){e.textColliders=x.textColliders;for(const e of x.textColliders){e.minLod=Math.max(l+(0,a.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,a.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),n=Math.sin(t),r=e.dxPixels*s-e.dyPixels*n,i=e.dxPixels*n+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*n,o=(e.dxPixels+e.width)*n+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*n,h=e.dxPixels*n+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*n,u=(e.dxPixels+e.width)*n+(e.dyPixels+e.height)*s,f=Math.min(r,a,l,c),d=Math.max(r,a,l,c),y=Math.min(i,o,h,u),g=Math.max(i,o,h,u);e.dxPixels=f,e.dyPixels=y,e.width=d-f,e.height=g-y}}}}if(g){const s=h.hasDataDrivenIcon?h.iconMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._addPlacedIcons(e,g.shapes,l,r.page,t.rotationAlignment===y.I5.VIEWPORT,s),g.iconColliders){e.iconColliders=g.iconColliders;for(const e of g.iconColliders){e.minLod=Math.max(l+(0,a.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,a.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),n=Math.sin(t),r=e.dxPixels*s-e.dyPixels*n,i=e.dxPixels*n+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*n,o=(e.dxPixels+e.width)*n+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*n,h=e.dxPixels*n+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*n,u=(e.dxPixels+e.width)*n+(e.dyPixels+e.height)*s,f=Math.min(r,a,l,c),d=Math.max(r,a,l,c),y=Math.min(i,o,h,u),g=Math.max(i,o,h,u);e.dxPixels=f,e.dyPixels=y,e.width=d-f,e.height=g-y}}}}}}_addPlacedIcons(e,t,s,n,r,i){const o=Math.max(s-1,0),l=this._iconVertexBuffer,h=this._iconIndexBuffer,c=this._markerMap;for(const u of t){const t=r?0:Math.max(s+(0,a.p6)(u.minzoom),o),f=r?25:Math.min(s+(0,a.p6)(u.maxzoom),25);if(f<=t)continue;const d=u.tl,y=u.tr,g=u.bl,x=u.br,p=u.mosaicRect,m=u.labelAngle,_=u.minAngle,I=u.maxAngle,b=u.anchor,M=l.index,w=p.x,P=p.y,T=w+p.width,A=P+p.height,D=l.index;l.add(b.x,b.y,d.x,d.y,w,P,m,_,I,t,f,i),l.add(b.x,b.y,y.x,y.y,T,P,m,_,I,t,f,i),l.add(b.x,b.y,g.x,g.y,w,A,m,_,I,t,f,i),l.add(b.x,b.y,x.x,x.y,T,A,m,_,I,t,f,i),e.iconVertexRanges.length>0&&e.iconVertexRanges[0][0]+e.iconVertexRanges[0][1]===D?e.iconVertexRanges[0][1]+=4:e.iconVertexRanges.push([D,4]),h.add(M,M+1,M+2),h.add(M+1,M+2,M+3),c.has(n)?c.get(n)[1]+=6:c.set(n,[this._iconIndexStart+this._iconIndexCount,6]),this._iconIndexCount+=6}}_addPlacedGlyphs(){const e=this._textVertexBuffer,t=this._textIndexBuffer,s=this._glyphMap;for(const[n,r]of this._glyphBufferDataStorage)for(const i of r){const r=e.index,a=i.symbolInstance,o=i.ddAttributes,l=e.index;e.add(i.glyphAnchor[0],i.glyphAnchor[1],i.tl[0],i.tl[1],i.xmin,i.ymin,i.labelAngle,i.minAngle,i.maxAngle,i.minLod,i.maxLod,o),e.add(i.glyphAnchor[0],i.glyphAnchor[1],i.tr[0],i.tr[1],i.xmax,i.ymin,i.labelAngle,i.minAngle,i.maxAngle,i.minLod,i.maxLod,o),e.add(i.glyphAnchor[0],i.glyphAnchor[1],i.bl[0],i.bl[1],i.xmin,i.ymax,i.labelAngle,i.minAngle,i.maxAngle,i.minLod,i.maxLod,o),e.add(i.glyphAnchor[0],i.glyphAnchor[1],i.br[0],i.br[1],i.xmax,i.ymax,i.labelAngle,i.minAngle,i.maxAngle,i.minLod,i.maxLod,o),a.textVertexRanges.length>0&&a.textVertexRanges[0][0]+a.textVertexRanges[0][1]===l?a.textVertexRanges[0][1]+=4:a.textVertexRanges.push([l,4]),t.add(r,r+1,r+2),t.add(r+1,r+2,r+3),s.has(n)?s.get(n)[1]+=6:s.set(n,[this._textIndexStart+this._textIndexCount,6]),this._textIndexCount+=6}this._glyphBufferDataStorage.clear()}_storePlacedGlyphs(e,t,s,n,r){const i=Math.max(s-1,0),o=n===y.I5.VIEWPORT;let l,h,c,u,f,d,g,x,p,m,_;for(const n of t)l=o?0:Math.max(s+(0,a.p6)(n.minzoom),i),h=o?25:Math.min(s+(0,a.p6)(n.maxzoom),25),h<=l||(c=n.tl,u=n.tr,f=n.bl,d=n.br,g=n.labelAngle,x=n.minAngle,p=n.maxAngle,m=n.anchor,_=n.mosaicRect,this._glyphBufferDataStorage.has(n.page)||this._glyphBufferDataStorage.set(n.page,[]),this._glyphBufferDataStorage.get(n.page).push({glyphAnchor:[m.x,m.y],tl:[c.x,c.y],tr:[u.x,u.y],bl:[f.x,f.y],br:[d.x,d.y],xmin:_.x,ymin:_.y,xmax:_.x+_.width,ymax:_.y+_.height,labelAngle:g,minAngle:x,maxAngle:p,minLod:l,maxLod:h,placementLod:i,symbolInstance:e,ddAttributes:r}))}static _pushAnchors(e,t,s,n){s+=n;let r=0;const o=t.length-1;for(let e=0;e<o;e++)r+=i.bR.distance(t[e],t[e+1]);let l=n||s;if(l*=.5,r<=l)return;const h=l/r;let c=0,u=-(s=r/Math.max(Math.round(r/s),1))/2;const f=t.length-1;for(let n=0;n<f;n++){const r=t[n],i=t[n+1],o=i.x-r.x,l=i.y-r.y,f=Math.sqrt(o*o+l*l);let d;for(;u+s<c+f;){u+=s;const t=(u-c)/f,y=(0,a.GW)(r.x,i.x,t),g=(0,a.GW)(r.y,i.y,t);void 0===d&&(d=Math.atan2(l,o)),e.push(new x(y,g,d,n,h))}c+=f}}static _pushCenterAnchor(e,t){let s=0;const n=t.length-1;for(let e=0;e<n;e++)s+=i.bR.distance(t[e],t[e+1]);const r=s/2;let o=0;const l=t.length-1;for(let s=0;s<l;s++){const n=t[s],i=t[s+1],l=i.x-n.x,h=i.y-n.y,c=Math.sqrt(l*l+h*h);if(r<o+c){const t=(r-o)/c,u=(0,a.GW)(n.x,i.x,t),f=(0,a.GW)(n.y,i.y,t),d=Math.atan2(h,l);return void e.push(new x(u,f,d,s,0))}o+=c}}static _deviation(e,t,s){const n=(t.x-e.x)*(s.x-t.x)+(t.y-e.y)*(s.y-t.y),r=(t.x-e.x)*(s.y-t.y)-(t.y-e.y)*(s.x-t.x);return Math.atan2(r,n)}static _honorsTextMaxAngle(e,t,s,n,r){let a=0;const o=s/2;let l=new i.bR(t.x,t.y),h=t.segment+1;for(;a>-o;){if(--h,h<0)return!1;a-=i.bR.distance(e[h],l),l=e[h]}a+=i.bR.distance(e[h],e[h+1]);const c=[];let u=0;const f=e.length;for(;a<o;){const t=e[h];let s,o=h;do{if(++o,o===f)return!1;s=e[o]}while(s.isEqual(t));let l,d=o;do{if(++d,d===f)return!1;l=e[d]}while(l.isEqual(s));const y=this._deviation(t,s,l);for(c.push({deviation:y,distToAnchor:a}),u+=y;a-c[0].distToAnchor>r;)u-=c.shift().deviation;if(Math.abs(u)>n)return!1;a+=i.bR.distance(s,l),h=o}return!0}static _smoothVertices(e,t){if(t<=0)return e;let s=e.length;if(s<3)return e;const n=[];let r=0,a=0;n.push(0);for(let t=1;t<s;t++){const s=i.bR.distance(e[t],e[t-1]);s>0&&(r+=s,n.push(r),a++,a!==t&&(e[a]=e[t]))}if(s=a+1,s<3)return e;t=Math.min(t,.2*r);const o=e[0].x,l=e[0].y,h=e[s-1].x,c=e[s-1].y,u=i.bR.sub(e[0],e[1]);u.normalize(),e[0].x+=t*u.x,e[0].y+=t*u.y,u.assignSub(e[s-1],e[s-2]),u.normalize(),e[s-1].x+=t*u.x,e[s-1].y+=t*u.y,n[0]-=t,n[s-1]+=t;const f=[];f.push(new i.bR(o,l));const d=1e-6,y=.5*t;for(let r=1;r<s-1;r++){let a=0,o=0,l=0;for(let s=r-1;s>=0;s--){const i=y+n[s+1]-n[r];if(i<0)break;const h=n[s+1]-n[s],c=n[r]-n[s]<y?1:i/h;if(c<d)break;const u=c*c,f=c*i-.5*u*h,g=c*h/t,x=e[s+1],p=e[s].x-x.x,m=e[s].y-x.y;a+=g/f*(x.x*c*i+.5*u*(i*p-h*x.x)-u*c*h*p/3),o+=g/f*(x.y*c*i+.5*u*(i*m-h*x.y)-u*c*h*m/3),l+=g}for(let i=r+1;i<s;i++){const s=y-n[i-1]+n[r];if(s<0)break;const h=n[i]-n[i-1],c=n[i]-n[r]<y?1:s/h;if(c<d)break;const u=c*c,f=c*s-.5*u*h,g=c*h/t,x=e[i-1],p=e[i].x-x.x,m=e[i].y-x.y;a+=g/f*(x.x*c*s+.5*u*(s*p-h*x.x)-u*c*h*p/3),o+=g/f*(x.y*c*s+.5*u*(s*m-h*x.y)-u*c*h*m/3),l+=g}f.push(new i.bR(a/l,o/l))}return f.push(new i.bR(h,c)),e[0].x=o,e[0].y=l,e[s-1].x=h,e[s-1].y=c,f}static _pushCentroid(e,t){const s=4096,n=4096,r=t.length-1;let i=0,a=0,o=0,l=t[0].x,h=t[0].y;l>s&&(l=s),l<0&&(l=0),h>n&&(h=n),h<0&&(h=0);for(let e=1;e<r;e++){let r=t[e].x,c=t[e].y,u=t[e+1].x,f=t[e+1].y;r>s&&(r=s),r<0&&(r=0),c>n&&(c=n),c<0&&(c=0),u>s&&(u=s),u<0&&(u=0),f>n&&(f=n),f<0&&(f=0);const d=(r-l)*(f-h)-(u-l)*(c-h);i+=d*(l+r+u),a+=d*(h+c+f),o+=d}i/=3*o,a/=3*o,isNaN(i)||isNaN(a)||e.push(new x(i,a))}}J._bidiEngine=new q.A,function(e){e[e.INITIALIZED=0]="INITIALIZED",e[e.NO_DATA=1]="NO_DATA",e[e.READY=2]="READY",e[e.MODIFIED=3]="MODIFIED",e[e.INVALID=4]="INVALID"}(K||(K={}));class Z{constructor(e,t,s,n,r,o){if(this._pbfTiles={},this._tileClippers={},this._client=s,this._tile=t,this._sourceDataMaxLOD=n,o){this._styleLayerUIDs=new Set;for(const e of o)this._styleLayerUIDs.add(e)}this._styleRepository=r,this._layers=this._styleRepository?.layers??[];const[l,h,c]=t.tileKey.split("/").map(parseFloat);this._level=l;const u=(0,a.IU)(this._level);for(const t of Object.keys(e)){const s=e[t];if(this._pbfTiles[t]=new w.A(new Uint8Array(s.protobuff),new DataView(s.protobuff)),s.refKey){const[e]=s.refKey.split("/").map(parseFloat),n=l-e;if(n>0){const e=(1<<n)-1,s=h&e,r=c&e;this._tileClippers[t]=new i.O3(n,s,r,8,u)}}this._tileClippers[t]||(this._tileClippers[t]=new i.Ox)}}_canParseStyleLayer(e){return!this._styleLayerUIDs||this._styleLayerUIDs.has(e)}async parse(e){const t=(0,P.F)(),s=this._initialize(e),{returnedBuckets:n}=s;this._processLayers(s),this._linkReferences(s),this._filterFeatures(s);const r=[],i=new Set,a=(e,t)=>{i.has(e)||(r.push({name:e,repeat:t}),i.add(e))},o={};for(const e of n)e.getResources(e.tileClipper,a,o);if(this._tile.status===K.INVALID)return[];const l=this._fetchResources(r,o,e);return Promise.all([...l,t]).then((()=>this._processFeatures(s.returnedBuckets)))}_initialize(e){const t=e?.signal;return{signal:t,sourceNameToTileData:this._parseTileData(this._pbfTiles),layers:this._layers,zoom:this._level,sourceNameToTileClipper:this._tileClippers,sourceNameToUniqueSourceLayerBuckets:{},sourceNameToUniqueSourceLayers:{},returnedBuckets:[],layerIdToBucket:{},referencerUIDToReferencedId:new Map}}_processLayers(e){const{sourceNameToTileData:t,zoom:s,layers:n,sourceNameToTileClipper:r,sourceNameToUniqueSourceLayerBuckets:i,sourceNameToUniqueSourceLayers:a,returnedBuckets:o,layerIdToBucket:l,referencerUIDToReferencedId:h}=e,c=this._sourceDataMaxLOD;for(let e=n.length-1;e>=0;e--){const u=n[e];if(s<c){if(u.minzoom&&s<Math.floor(u.minzoom)||u.maxzoom&&s>=u.maxzoom)continue}else if(u.maxzoom&&s>=u.maxzoom)continue;if(u.type===y.Dc.BACKGROUND||!this._canParseStyleLayer(u.uid)||!t[u.source]||!r[u.source])continue;const f=t[u.source],d=r[u.source],g=u.sourceLayer,x=f[g];if(x){let e=a[u.source];if(e||(e=a[u.source]=new Set),e.add(u.sourceLayer),u.refLayerId)h.set(u.uid,u.refLayerId);else{const e=this._createBucket(u);if(e){e.layerUIDs=[u.uid],e.layerExtent=x.extent,e.tileClipper=d;let t=i[u.source];t||(t=i[u.source]={});let s=t[g];s||(s=t[g]=[]),s.push(e),o.push(e),l[u.id]=e}}}}}_linkReferences(e){const{layerIdToBucket:t,referencerUIDToReferencedId:s}=e;s.forEach(((e,s)=>{t[e]&&t[e].layerUIDs.push(s)}))}_filterFeatures(e){const{signal:t,sourceNameToTileData:s,sourceNameToUniqueSourceLayerBuckets:r,sourceNameToUniqueSourceLayers:i}=e,a=10*this._level,o=10*(this._level+1),l=[],h=[];for(const e of Object.keys(i))i[e].forEach((t=>{l.push(t),h.push(e)}));for(let e=0;e<l.length;e++){const i=h[e],c=l[e];if(!s[i]||!r[i])continue;const u=s[i][c],f=r[i][c];if(!f||0===f.length)continue;if((0,n.G4)(t))return;let d=0;const y=u.getData();for(;y.nextTag(2);){const e=y.getMessage(),t=new T(e,u,d++);e.release();const s=t.values;if(s){const e=s._minzoom;if(e&&e>=o)continue;const t=s._maxzoom;if(t&&t<=a)continue}for(const e of f)e.pushFeature(t)}}}_fetchResources(e,t,s){const n=[],r=this._tile.getWorkerTileHandler();let i,a;e.length>0&&(i=r.fetchSprites(e,this._client,s),n.push(i));for(const e in t){const i=t[e];i.size>0&&(a=r.fetchGlyphs(this._tile.tileKey,e,i,this._client,s),n.push(a))}return n}_processFeatures(e){const t=e.filter((e=>e.hasFeatures()||this._canParseStyleLayer(e.layer.uid)));for(const e of t)e.processFeatures(e.tileClipper);return t}_parseTileData(e){const t={};for(const s of Object.keys(e)){const n=e[s],r={};for(;n.next();)switch(n.tag()){case 3:{const e=n.getMessage(),t=new k(e);e.release(),r[t.name]=t;break}default:n.skip()}t[s]=r}return t}_createBucket(e){switch(e.type){case y.Dc.BACKGROUND:return null;case y.Dc.FILL:return this._createFillBucket(e);case y.Dc.LINE:return this._createLineBucket(e);case y.Dc.CIRCLE:return this._createCircleBucket(e);case y.Dc.SYMBOL:return this._createSymbolBucket(e)}}_createFillBucket(e){return new F(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new B(e.fillMaterial.getStride()),new D,new V(e.outlineMaterial.getStride()),new D)}_createLineBucket(e){return new N(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new L(e.lineMaterial.getStride()),new D)}_createCircleBucket(e){return new C(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new R(e.circleMaterial.getStride()),new D)}_createSymbolBucket(e){const t=this._tile;return new J(t.tileKey,e,this._level,new v(e.iconMaterial.getStride()),new D,new v(e.textMaterial.getStride()),new D,t.placementEngine,t.getWorkerTileHandler())}}class ${constructor(e,t,s,n){this.status=K.INITIALIZED,this.placementEngine=new I,this.tileKey=e,this.refKeys=t,this._workerTileHandler=s,this._styleRepository=n}release(){this.tileKey="",this.refKeys=null,this.status=K.INITIALIZED,this._workerTileHandler=null}async parse(e,t){const s=t?.signal;if(null!=s){const e=()=>{s.removeEventListener("abort",e),this.status=K.INVALID};s.addEventListener("abort",e)}let r;const i={bucketsWithData:[],emptyBuckets:null};try{r=await this._parse(e,t)}catch(e){if((0,n.zf)(e))throw e;return{result:i,transferList:[]}}this.status=K.READY;const a=i.bucketsWithData,o=[];for(const e of r)if(e.hasFeatures()){const t=e.serialize();a.push(t)}else o.push(e.layer.uid);const l=[...a];let h=null;return o.length>0&&(h=Uint32Array.from(o),l.push(h.buffer)),i.emptyBuckets=h,{result:i,transferList:l}}setObsolete(){this.status=K.INVALID}getLayers(){return this._workerTileHandler.getLayers()}getWorkerTileHandler(){return this._workerTileHandler}async _parse(e,t){const s=e.sourceName2DataAndRefKey;return 0===Object.keys(s).length?[]:(this.status=K.MODIFIED,new Z(s,this,t.client,e.sourceDataMaxLOD,this._styleRepository,e.styleLayerUIDs).parse(t))}}var Q=s(45013);class X{constructor(){this._spriteInfo={},this._glyphInfo={},this._sourceDataMaxLOD=25}reset(){return this._spriteInfo={},this._glyphInfo={},Promise.resolve()}getLayers(){return this._styleRepository?.layers??[]}async createTileAndParse(e,t){const{key:s}=e,r={};for(const t of Object.keys(e.sourceName2DataAndRefKey)){const s=e.sourceName2DataAndRefKey[t];r[t]=s.refKey}const i=new $(s,r,this,this._styleRepository);try{return await i.parse({...e,sourceDataMaxLOD:this._sourceDataMaxLOD},t)}catch(e){if(i.setObsolete(),i.release(),!(0,n.zf)(e))throw e;return null}}updateStyle(e){if(!e||0===e.length||!this._styleRepository)return;const t=this._styleRepository;for(const s of e){const e=s.type,n=s.data;switch(e){case r.$q.PAINTER_CHANGED:t.setPaintProperties(n.layer,n.paint);break;case r.$q.LAYOUT_CHANGED:t.setLayoutProperties(n.layer,n.layout);break;case r.$q.LAYER_REMOVED:t.deleteStyleLayer(n.layer);break;case r.$q.LAYER_CHANGED:t.setStyleLayer(n.layer,n.index);break;case r.$q.SPRITES_CHANGED:this._spriteInfo={}}}}setStyle(e){const{style:t,sourceDataMaxLOD:s}=e;this._styleRepository=new Q.A(t),this._sourceDataMaxLOD=s,this._spriteInfo={},this._glyphInfo={}}fetchSprites(e,t,s){const n=[],r=this._spriteInfo;for(const t of e)void 0===r[t.name]&&n.push(t);return 0===n.length?Promise.resolve():t.invoke("getSprites",n,{signal:s?.signal}).then((e=>{for(const t in e){const s=e[t];r[t]=s}}))}getSpriteItems(){return this._spriteInfo}fetchGlyphs(e,t,s,n,r){const i=[];let a=this._glyphInfo[t];return a?s.forEach((e=>{a[e]||i.push(e)})):(a=this._glyphInfo[t]=[],s.forEach((e=>i.push(e)))),0===i.length?Promise.resolve():n.invoke("getGlyphs",{tileID:e,font:t,codePoints:i},r).then((e=>{for(let t=0;t<e.length;t++)e[t]&&(a[t]=e[t])}))}getGlyphItems(e){return this._glyphInfo[e]}}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5804,6742],{92071:(e,t,r)=>{r.d(t,{P:()=>w,L:()=>S});var i=r(90237),s=r(69622),o=r(76953),n=r(4718),a=r(35666);class l{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(a.AU),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new l,r=this._originStores[a.Gr.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,n.o8)(e),a.Gr.DEFAULTS)}));for(let r=a.Gr.SERVICE;r<a.AU;r++){const i=this._originStores[r];i&&i.forEach(((i,s)=>{e&&e.has(s)||t.set(s,(0,n.o8)(i),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=a.Gr.USER){let i=this._originStores[r];if(i||(i=new Map,this._originStores[r]=i),i.set(e,t),!this._values.has(e)||this._propertyOriginMap.get(e)<=r){const i=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),i!==t}return!1}delete(e,t=a.Gr.USER){const r=this._originStores[t];if(!r)return;const i=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return i}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],i=r?.get(e),s=this._values.get(e);return this._values.set(e,i),this._propertyOriginMap.set(e,t),s!==i}originOf(e){return this._propertyOriginMap.get(e)||a.Gr.DEFAULTS}forEach(e){this._values.forEach(e)}}var u=r(45917),d=r(88620),p=r(40608);const c=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,d.oY)(this),r=t.store,i=new l;t.store=i,(0,o.k)(t,r,i)}read(e,t){(0,u.L)(this,e,t)}getAtOrigin(e,t){const r=h(this),i=(0,a.aB)(t);if("string"==typeof e)return r.get(e,i);const s={};return e.forEach((e=>{s[e]=r.get(e,i)})),s}originOf(e){return(0,a.OL)(this.originIdOf(e))}originIdOf(e){return h(this).originOf(e)}revert(e,t){const r=h(this),i=(0,a.aB)(t),s=(0,d.oY)(this);let o;o="string"==typeof e?"*"===e?r.keys(i):[e]:e,o.forEach((e=>{s.invalidate(e),r.revert(e,i),s.commit(e)}))}};return t=(0,i._)([(0,p.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function h(e){return(0,d.oY)(e).store}let y=class extends(c(s.A)){};y=(0,i._)([(0,p.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],y);var f=r(16649),g=r(49422);const m=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return v(this).delete(e,(0,a.aB)(t))}write(e,t){return(0,g.M)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,d.oY)(this).setAtOrigin(e,t,(0,a.aB)(r))}removeOrigin(e){const t=v(this),r=(0,a.aB)(e),i=t.keys(r);for(const e of i)t.originOf(e)===r&&t.set(e,t.get(e,r),a.Gr.USER)}updateOrigin(e,t){const r=v(this),i=(0,a.aB)(t),s=(0,f.Jt)(this,e);for(let t=i+1;t<a.AU;++t)r.delete(e,t);r.set(e,s,i)}toJSON(e){return this.write({},e)}};return t=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function v(e){return(0,d.oY)(e).store}const w=e=>{let t=class extends(m(c(e))){constructor(...e){super(...e)}};return t=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport")],t),t};let S=class extends(w(s.A)){};S=(0,i._)([(0,p.$)("esri.core.MultiOriginJSONSupport")],S)},46130:(e,t,r)=>{r.d(t,{v:()=>s});var i=r(76553);function s(e){e?.writtenProperties&&e.writtenProperties.forEach((({target:e,propName:t,newOrigin:r})=>{(0,i.H)(e)&&r&&e.originOf(t)!==r&&e.updateOrigin(t,r)}))}},76553:(e,t,r)=>{function i(e){return e&&"getAtOrigin"in e&&"originOf"in e}r.d(t,{H:()=>i})},13069:(e,t,r)=>{r.d(t,{AG:()=>a,lk:()=>s,vD:()=>n,yS:()=>o});const i="randomUUID"in crypto;function s(){if(i)return crypto.randomUUID();const e=crypto.getRandomValues(new Uint16Array(8));e[3]=4095&e[3]|16384,e[4]=16383&e[4]|32768;const t=t=>e[t].toString(16).padStart(4,"0");return t(0)+t(1)+"-"+t(2)+"-"+t(3)+"-"+t(4)+"-"+t(5)+t(6)+t(7)}function o(){return`{${s().toUpperCase()}}`}function n(){return`{${s()}}`}function a(e){const t=e.toUpperCase();return"{"!==e[0]?`{${t}}`:t}},54239:(e,t,r)=>{r.d(t,{A:()=>w});var i,s=r(90237),o=r(4576),n=r(66552),a=r(25482),l=r(83047),u=r(67076),d=r(10107),p=(r(44208),r(53966),r(36005)),c=r(40608),h=r(43937);const y=(0,n.O)()({orthometric:"gravity-related-height",gravity_related_height:"gravity-related-height",ellipsoidal:"ellipsoidal"}),f=y.jsonValues.slice();(0,o.Xy)(f,"orthometric");const g=(0,n.O)()({meter:"meters",foot:"feet","us-foot":"us-feet","clarke-foot":"clarke-feet","clarke-yard":"clarke-yards","clarke-link":"clarke-links","sears-yard":"sears-yards","sears-foot":"sears-feet","sears-chain":"sears-chains","benoit-1895-b-chain":"benoit-1895-b-chains","indian-yard":"indian-yards","indian-1937-yard":"indian-1937-yards","gold-coast-foot":"gold-coast-feet","sears-1922-truncated-chain":"sears-1922-truncated-chains","50-kilometers":"50-kilometers","150-kilometers":"150-kilometers"});let m=i=class extends a.A{constructor(e){super(e),this.heightModel="gravity-related-height",this.heightUnit="meters",this.vertCRS=null}writeHeightModel(e,t,r){return y.write(e,t,r)}readHeightModel(e,t,r){return y.read(e)||(r?.messages&&r.messages.push(function(e,t){return new u.A("height-model:unsupported",`Height model of value '${e}' is not supported`,t)}(e,{context:r})),null)}readHeightUnit(e,t,r){return g.read(e)||(r?.messages&&r.messages.push(v(e,{context:r})),null)}readHeightUnitService(e,t,r){return(0,l.LA)(e)||g.read(e)||(r?.messages&&r.messages.push(v(e,{context:r})),null)}readVertCRS(e,t){return t.vertCRS||t.ellipsoid||t.geoid}clone(){return new i({heightModel:this.heightModel,heightUnit:this.heightUnit,vertCRS:this.vertCRS})}equals(e){return!!e&&(this===e||this.heightModel===e.heightModel&&this.heightUnit===e.heightUnit&&this.vertCRS===e.vertCRS)}static deriveUnitFromSR(e,t){const r=(0,l.k1)(t);return new i({heightModel:e.heightModel,heightUnit:r??void 0,vertCRS:e.vertCRS})}write(e,t){return t={origin:"web-scene",...t},super.write(e,t)}static fromJSON(e){if(!e)return null;const t=new i;return t.read(e,{origin:"web-scene"}),t}};function v(e,t){return new u.A("height-unit:unsupported",`Height unit of value '${e}' is not supported`,t)}(0,s._)([(0,d.MZ)({type:y.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:f,default:"ellipsoidal",write:{isRequired:!0}}}}})],m.prototype,"heightModel",void 0),(0,s._)([(0,h.K)("web-scene","heightModel")],m.prototype,"writeHeightModel",null),(0,s._)([(0,p.w)(["web-scene","service"],"heightModel")],m.prototype,"readHeightModel",null),(0,s._)([(0,d.MZ)({type:g.apiValues,constructOnly:!0,json:{origins:{"web-scene":{type:g.jsonValues,write:{writer:g.write,isRequired:!0}}}}})],m.prototype,"heightUnit",void 0),(0,s._)([(0,p.w)("web-scene","heightUnit")],m.prototype,"readHeightUnit",null),(0,s._)([(0,p.w)("service","heightUnit")],m.prototype,"readHeightUnitService",null),(0,s._)([(0,d.MZ)({type:String,constructOnly:!0,json:{origins:{"web-scene":{write:!0}}}})],m.prototype,"vertCRS",void 0),(0,s._)([(0,p.w)("service","vertCRS",["vertCRS","ellipsoid","geoid"])],m.prototype,"readVertCRS",null),m=i=(0,s._)([(0,c.$)("esri.geometry.HeightModelInfo")],m);const w=m},4146:(e,t,r)=>{r.d(t,{A:()=>S});var i=r(90237),s=r(78888),o=r(49186),n=r(65529),a=r(4902),l=r(92474),u=r(53966),d=r(74887),p=r(84952),c=r(10107),h=(r(44208),r(87811),r(40608)),y=r(5443),f=r(16930),g=r(92602),m=r(79677);let v=0,w=class extends(n.A.EventedMixin(a.A.IdentifiableMixin(l.A))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new y.A(-180,-90,180,90,f.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+v++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=f.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0,this.createLayerView=void 0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await r.e(7982).then(r.bind(r,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:i}=await r.e(5613).then(r.bind(r,45613));try{return await i(t)}catch(e){const r=t?.portalItem,i=r?.id||"unset",s=r?.portal?.url||g.A.portalUrl;throw u.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+s+"', id: '"+i+"')",e),e}}(e)}initialize(){this.when().catch((e=>{(0,d.zf)(e)||u.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})}))}destroy(){const e=this.parent;if(e){const t=this;"layers"in e&&e.layers.includes(t)?e.layers.remove(t):"tables"in e&&e.tables.includes(t)?e.tables.remove(t):"baseLayers"in e&&e.baseLayers.includes(t)?e.baseLayers.remove(t):"referenceLayers"in e&&e.referenceLayers.includes(t)&&e.referenceLayers.remove(t),this._set("parent",null)}}get effectiveVisible(){let e=this.visible;const t=this.parent;return e&&t&&"effectiveVisible"in t&&(e&&=t.effectiveVisible),e}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){return(0,p.An)(this.url)}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,s.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,i._)([(0,c.MZ)({type:String})],w.prototype,"attributionDataUrl",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],w.prototype,"effectiveVisible",null),(0,i._)([(0,c.MZ)({type:y.A})],w.prototype,"fullExtent",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],w.prototype,"hasAttributionData",null),(0,i._)([(0,c.MZ)({type:String,clonable:!1})],w.prototype,"id",void 0),(0,i._)([(0,c.MZ)({type:Boolean,nonNullable:!0})],w.prototype,"legendEnabled",void 0),(0,i._)([(0,c.MZ)({type:["show","hide","hide-children"]})],w.prototype,"listMode",void 0),(0,i._)([(0,c.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],w.prototype,"opacity",void 0),(0,i._)([(0,c.MZ)({clonable:!1})],w.prototype,"parent",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],w.prototype,"parsedUrl",null),(0,i._)([(0,c.MZ)({type:Boolean,readOnly:!0})],w.prototype,"persistenceEnabled",void 0),(0,i._)([(0,c.MZ)({type:Boolean})],w.prototype,"popupEnabled",void 0),(0,i._)([(0,c.MZ)({type:Boolean})],w.prototype,"attributionVisible",void 0),(0,i._)([(0,c.MZ)({type:f.A})],w.prototype,"spatialReference",void 0),(0,i._)([(0,c.MZ)({type:String})],w.prototype,"title",void 0),(0,i._)([(0,c.MZ)({readOnly:!0,json:{read:!1}})],w.prototype,"type",void 0),(0,i._)([(0,c.MZ)()],w.prototype,"url",void 0),(0,i._)([(0,c.MZ)({type:m.A})],w.prototype,"visibilityTimeExtent",void 0),(0,i._)([(0,c.MZ)({type:Boolean,nonNullable:!0})],w.prototype,"visible",void 0),w=(0,i._)([(0,h.$)("esri.layers.Layer")],w);const S=w},76742:(e,t,r)=>{r.r(t),r.d(t,{default:()=>te});var i=r(90237),s=r(13874),o=r(78888),n=r(49186),a=r(4718),l=r(53966),u=r(92071),d=r(93637),p=r(74887),c=r(84952),h=r(10107),y=(r(44208),r(36005)),f=r(40608),g=r(43937),m=r(4146),v=r(52136),w=r(18768),S=r(69208),_=r(16131),b=r(8303),I=r(25036),A=r(58947),x=r(56507),M=r(93223),P=r(25482);r(87811);let R=class extends P.A{constructor(e){super(e),this.field=null,this.type=null}clone(){return console.warn(".clone() is not implemented for "+this.declaredClass),null}};(0,i._)([(0,h.MZ)({type:String,json:{write:{enabled:!0,isRequired:!0}}})],R.prototype,"field",void 0),(0,i._)([(0,h.MZ)({readOnly:!0,nonNullable:!0,json:{read:!1,write:{isRequired:!0}}})],R.prototype,"type",void 0),R=(0,i._)([(0,f.$)("esri.layers.pointCloudFilters.PointCloudFilter")],R);const O=R;var U;let E=U=class extends O{constructor(e){super(e),this.requiredClearBits=null,this.requiredSetBits=null,this.type="bitfield"}clone(){return new U({field:this.field,requiredClearBits:(0,a.o8)(this.requiredClearBits),requiredSetBits:(0,a.o8)(this.requiredSetBits)})}};(0,i._)([(0,h.MZ)({type:[x.jz],json:{write:{enabled:!0,overridePolicy(){return{enabled:!0,isRequired:!this.requiredSetBits}}}}})],E.prototype,"requiredClearBits",void 0),(0,i._)([(0,h.MZ)({type:[x.jz],json:{write:{enabled:!0,overridePolicy(){return{enabled:!0,isRequired:!this.requiredClearBits}}}}})],E.prototype,"requiredSetBits",void 0),(0,i._)([(0,M.e)({pointCloudBitfieldFilter:"bitfield"})],E.prototype,"type",void 0),E=U=(0,i._)([(0,f.$)("esri.layers.pointCloudFilters.PointCloudBitfieldFilter")],E);const F=E;var Z;let L=Z=class extends O{constructor(e){super(e),this.includedReturns=[],this.type="return"}clone(){return new Z({field:this.field,includedReturns:(0,a.o8)(this.includedReturns)})}};(0,i._)([(0,h.MZ)({type:[["firstOfMany","last","lastOfMany","single"]],json:{write:{enabled:!0,isRequired:!0}}})],L.prototype,"includedReturns",void 0),(0,i._)([(0,M.e)({pointCloudReturnFilter:"return"})],L.prototype,"type",void 0),L=Z=(0,i._)([(0,f.$)("esri.layers.pointCloudFilters.PointCloudReturnFilter")],L);const j=L;var N;let T=N=class extends O{constructor(e){super(e),this.mode="exclude",this.type="value",this.values=[]}clone(){return new N({field:this.field,mode:this.mode,values:(0,a.o8)(this.values)})}};(0,i._)([(0,h.MZ)({type:["exclude","include"],json:{write:{enabled:!0,isRequired:!0}}})],T.prototype,"mode",void 0),(0,i._)([(0,M.e)({pointCloudValueFilter:"value"})],T.prototype,"type",void 0),(0,i._)([(0,h.MZ)({type:[Number],json:{write:{enabled:!0,isRequired:!0}}})],T.prototype,"values",void 0),T=N=(0,i._)([(0,f.$)("esri.layers.pointCloudFilters.PointCloudValueFilter")],T);const C={key:"type",base:O,typeMap:{value:T,bitfield:F,return:j}};var $,k=r(10873),q=r(20437),B=r(17036),V=r(93705),K=r(63531),D=r(51857);let H=$=class extends D.A{constructor(e){super(e),this.type="point-cloud-rgb",this.field=null}clone(){return new $({...this.cloneProperties(),field:(0,a.o8)(this.field)})}};(0,i._)([(0,M.e)({pointCloudRGBRenderer:"point-cloud-rgb"})],H.prototype,"type",void 0),(0,i._)([(0,h.MZ)({type:String,json:{write:{isRequired:!0}}})],H.prototype,"field",void 0),H=$=(0,i._)([(0,f.$)("esri.renderers.PointCloudRGBRenderer")],H);const G=H;var J=r(69846),z=r(48425);const X={key:"type",base:D.A,typeMap:{"point-cloud-class-breaks":K.A,"point-cloud-rgb":G,"point-cloud-stretch":J.A,"point-cloud-unique-value":z.A},errorContext:"renderer"};var Q=r(24212),Y=r(30291);const W=(0,B.p)();let ee=class extends((0,A.w6)((0,w.b)((0,_.q)((0,b.A)((0,I.j)((0,u.P)((0,S.d)((0,v.p)(m.A))))))))){constructor(...e){super(...e),this.operationalLayerType="PointCloudLayer",this.popupEnabled=!0,this.popupTemplate=null,this.opacity=1,this.filters=[],this.fields=null,this.fieldsIndex=null,this.outFields=null,this.path=null,this.legendEnabled=!0,this.renderer=null,this.type="point-cloud"}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}get defaultPopupTemplate(){return this.attributeStorageInfo?this.createPopupTemplate():null}getFieldDomain(e){const t=this.fieldsIndex.get(e);return t?.domain?t.domain:null}readServiceFields(e,t,r){return Array.isArray(e)?e.map((e=>{const t=new q.A;return"FieldTypeInteger"===e.type&&((e=(0,a.o8)(e)).type="esriFieldTypeInteger"),t.read(e,r),t})):Array.isArray(t.attributeStorageInfo)?t.attributeStorageInfo.map((e=>new q.A({name:e.name,type:"ELEVATION"===e.name?"double":"integer"}))):null}set elevationInfo(e){this._set("elevationInfo",e),this._validateElevationInfo()}writeRenderer(e,t,r,i){(0,d.sM)("layerDefinition.drawingInfo.renderer",e.write({},i),t)}load(e){const t=null!=e?e.signal:null,r=this.loadFromPortal({supportedTypes:["Scene Service"]},e).catch(p.QP).then((()=>this._fetchService(t)));return this.addResolvingPromise(r),Promise.resolve(this)}createPopupTemplate(e){const t=(0,Y.tn)(this,e);return t&&(this._formatPopupTemplateReturnsField(t),this._formatPopupTemplateRGBField(t)),t}_formatPopupTemplateReturnsField(e){const t=this.fieldsIndex.get("RETURNS");if(!t)return;const r=e.fieldInfos?.find((e=>e.fieldName===t.name));if(!r)return;const i=new V.A({name:"pcl-returns-decoded",title:t.alias||t.name,expression:`\n var returnValue = $feature.${t.name};\n return (returnValue % 16) + " / " + Floor(returnValue / 16);\n `});e.expressionInfos=[...e.expressionInfos||[],i],r.fieldName="expression/pcl-returns-decoded"}_formatPopupTemplateRGBField(e){const t=this.fieldsIndex.get("RGB");if(!t)return;const r=e.fieldInfos?.find((e=>e.fieldName===t.name));if(!r)return;const i=new V.A({name:"pcl-rgb-decoded",title:t.alias||t.name,expression:`\n var rgb = $feature.${t.name};\n var red = Floor(rgb / 65536, 0);\n var green = Floor((rgb - (red * 65536)) / 256,0);\n var blue = rgb - (red * 65536) - (green * 256);\n\n return "rgb(" + red + "," + green + "," + blue + ")";\n `});e.expressionInfos=[...e.expressionInfos||[],i],r.fieldName="expression/pcl-rgb-decoded"}async queryCachedStatistics(e,t){if(await this.load(t),!this.attributeStorageInfo)throw new n.A("scenelayer:no-cached-statistics","Cached statistics are not available for this layer");const r=this.fieldsIndex.get(e);if(!r)throw new n.A("pointcloudlayer:field-unexisting",`Field '${e}' does not exist on the layer`);for(const e of this.attributeStorageInfo)if(e.name===r.name){const r=(0,c.fj)(this.parsedUrl?.path??"",`./statistics/${e.key}`);return(0,o.A)(r,{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:t?t.signal:null}).then((e=>e.data))}throw new n.A("pointcloudlayer:no-cached-statistics","Cached statistics for this attribute are not available")}async saveAs(e,t){return this._debouncedSaveOperations(A.Xh.SAVE_AS,{...t,getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"point-cloud"},e)}async save(){const e={getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"point-cloud"};return this._debouncedSaveOperations(A.Xh.SAVE,e)}validateLayer(e){if(e.layerType&&"PointCloud"!==e.layerType)throw new n.A("pointcloudlayer:layer-type-not-supported","PointCloudLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor))throw new n.A("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"1.x-2.x"});if(this.version.major>2)throw new n.A("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"1.x-2.x"})}hasCachedStatistics(e){return null!=this.attributeStorageInfo&&this.attributeStorageInfo.some((t=>t.name===e))}_getTypeKeywords(){return["PointCloud"]}_validateElevationInfo(){const e=this.elevationInfo;(0,Q.XF)(l.A.getLogger(this),(0,Q.B)("Point cloud layers","absolute-height",e)),(0,Q.XF)(l.A.getLogger(this),(0,Q.tW)("Point cloud layers",e))}};(0,i._)([(0,h.MZ)({type:["PointCloudLayer"]})],ee.prototype,"operationalLayerType",void 0),(0,i._)([(0,h.MZ)(k.M6)],ee.prototype,"popupEnabled",void 0),(0,i._)([(0,h.MZ)({type:s.A,json:{name:"popupInfo",write:!0}})],ee.prototype,"popupTemplate",void 0),(0,i._)([(0,h.MZ)({readOnly:!0,json:{read:!1}})],ee.prototype,"defaultPopupTemplate",null),(0,i._)([(0,h.MZ)({readOnly:!0,json:{write:!1,read:!1,origins:{"web-document":{write:!1,read:!1}}}})],ee.prototype,"opacity",void 0),(0,i._)([(0,h.MZ)({type:["show","hide"]})],ee.prototype,"listMode",void 0),(0,i._)([(0,h.MZ)({types:[C],json:{origins:{service:{read:{source:"filters"}}},name:"layerDefinition.filters",write:!0}})],ee.prototype,"filters",void 0),(0,i._)([(0,h.MZ)({type:[q.A]})],ee.prototype,"fields",void 0),(0,i._)([(0,h.MZ)(W.fieldsIndex)],ee.prototype,"fieldsIndex",void 0),(0,i._)([(0,y.w)("service","fields",["fields","attributeStorageInfo"])],ee.prototype,"readServiceFields",null),(0,i._)([(0,h.MZ)(W.outFields)],ee.prototype,"outFields",void 0),(0,i._)([(0,h.MZ)({readOnly:!0})],ee.prototype,"attributeStorageInfo",void 0),(0,i._)([(0,h.MZ)(k.Yj)],ee.prototype,"elevationInfo",null),(0,i._)([(0,h.MZ)({type:String,json:{origins:{"web-scene":{read:!0,write:!0},"portal-item":{read:!0,write:!0}},read:!1}})],ee.prototype,"path",void 0),(0,i._)([(0,h.MZ)(k.fV)],ee.prototype,"legendEnabled",void 0),(0,i._)([(0,h.MZ)({types:X,json:{origins:{service:{read:{source:"drawingInfo.renderer"}}},name:"layerDefinition.drawingInfo.renderer",write:{target:{"layerDefinition.drawingInfo.renderer":{types:X},"layerDefinition.drawingInfo.transparency":{type:Number}}}}})],ee.prototype,"renderer",void 0),(0,i._)([(0,g.K)("renderer")],ee.prototype,"writeRenderer",null),(0,i._)([(0,h.MZ)({json:{read:!1},readOnly:!0})],ee.prototype,"type",void 0),ee=(0,i._)([(0,f.$)("esri.layers.PointCloudLayer")],ee);const te=ee},52136:(e,t,r)=>{r.d(t,{p:()=>n});var i=r(90237),s=r(10107),o=(r(44208),r(53966),r(87811),r(40608));const n=e=>{let t=class extends e{get apiKey(){return this._isOverridden("apiKey")?this._get("apiKey"):"portalItem"in this?this.portalItem?.apiKey:null}set apiKey(e){null!=e?this._override("apiKey",e):(this._clearOverride("apiKey"),this.clear("apiKey","user"))}};return(0,i._)([(0,s.MZ)({type:String})],t.prototype,"apiKey",null),t=(0,i._)([(0,o.$)("esri.layers.mixins.APIKeyMixin")],t),t}},18768:(e,t,r)=>{r.d(t,{b:()=>l});var i=r(90237),s=r(53966),o=r(10107),n=(r(44208),r(87811),r(40608)),a=r(60694);const l=e=>{let t=class extends e{get title(){if(this._get("title")&&"defaults"!==this.originOf("title"))return this._get("title");if(this.url){const e=(0,a.qg)(this.url);if(e?.title)return e.title}return this._get("title")||""}set title(e){this._set("title",e)}set url(e){this._set("url",(0,a.Jf)(e,s.A.getLogger(this)))}};return(0,i._)([(0,o.MZ)()],t.prototype,"title",null),(0,i._)([(0,o.MZ)({type:String})],t.prototype,"url",null),t=(0,i._)([(0,n.$)("esri.layers.mixins.ArcGISService")],t),t}},69208:(e,t,r)=>{r.d(t,{d:()=>n});var i=r(90237),s=r(10107),o=(r(44208),r(53966),r(87811),r(40608));const n=e=>{let t=class extends e{constructor(){super(...arguments),this.customParameters=null}};return(0,i._)([(0,s.MZ)({type:Object,json:{write:{overridePolicy:e=>({enabled:!!(e&&Object.keys(e).length>0)})}}})],t.prototype,"customParameters",void 0),t=(0,i._)([(0,o.$)("esri.layers.mixins.CustomParametersMixin")],t),t}},8303:(e,t,r)=>{r.d(t,{A:()=>b});var i=r(90237),s=r(92602),o=r(70333),n=r(78888),a=r(60999),l=r(49186),u=r(53966),d=r(97768),p=r(74887),c=r(84952),h=r(10107),y=(r(44208),r(87811),r(36005)),f=r(40608),g=r(43937),m=r(83531),v=r(20655),w=r(80812),S=r(41318),_=r(10407);const b=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,d.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new w.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:i}=await r.e(1204).then(r.bind(r,41204));return(0,p.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,p.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch((e=>((0,p.QP)(e),!0))))}async setUserPrivileges(e,t){if(!s.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:i},content:{updateItem:s}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",s)}catch(e){(0,p.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const i=!o.id?.findCredential(this.url),s=e===r.id;if(s&&r.portal.user)return this._getUserPrivileges(r,i);let n,a;if(s)n=r.portal.url;else try{n=await(0,m.wI)(this.url,t)}catch(e){(0,p.QP)(e)}if(!n||!(0,c.b8)(n,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;a=await(o.id?.getCredential(`${n}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,p.QP)(e)}const l=!0,u=!1,d=!1;if(!a)return{features:{edit:l,fullEdit:u},content:{updateItem:d}};try{if(s?await r.reload():(r=new w.default({id:e,portal:{url:n}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,i)}catch(e){(0,p.QP)(e)}return{features:{edit:l,fullEdit:u},content:{updateItem:d}}}_getUserPrivileges(e,t){const r=(0,_.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,p.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?o.id?.findCredential(this.url):null;if(!t)return!0;const r=I.credential===t?I.user:await this._fetchEditingUser(e);return I.credential=t,I.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=o.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const i=`${r.owningSystemUrl}/sharing/rest`,s=v.A.getDefault();if(s&&s.loaded&&(0,c.S8)(s.restUrl)===(0,c.S8)(i))return s.user;const l=`${i}/community/self`,u=null!=e?e.signal:null,d=await(0,a.Ke)((0,n.A)(l,{authMode:"no-prompt",query:{f:"json"},signal:u}));return d.ok?S.A.fromJSON(d.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,i=this.portalItem?.id&&(this.portalItem.portal||v.A.getDefault());return r&&i&&!(0,c.ut)(i.restUrl,r.restUrl)?(t.messages&&t.messages.push(new l.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i._)([(0,h.MZ)({type:w.default})],t.prototype,"portalItem",null),(0,i._)([(0,y.w)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,i._)([(0,g.K)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,i._)([(0,h.MZ)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasFullEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasUpdateItemPrivileges",void 0),t=(0,i._)([(0,f.$)("esri.layers.mixins.PortalLayer")],t),t},I={credential:null,user:null}},25036:(e,t,r)=>{r.d(t,{j:()=>n});var i=r(90237),s=r(10107),o=(r(44208),r(53966),r(87811),r(40608));const n=e=>{let t=class extends e{constructor(){super(...arguments),this.minScale=0,this.maxScale=0}get effectiveScaleRange(){const e={minScale:this.minScale,maxScale:this.maxScale},t=this.parent;t&&"effectiveScaleRange"in t&&function(e,t){e.minScale=e.minScale>0?t.minScale>0?Math.min(e.minScale,t.minScale):e.minScale:t.minScale,e.maxScale=e.maxScale>0?t.maxScale>0?Math.max(e.maxScale,t.maxScale):e.maxScale:t.maxScale}(e,t.effectiveScaleRange);const r=this._get("effectiveScaleRange");return r&&r.minScale===e.minScale&&r.maxScale===e.maxScale?r:e}};return(0,i._)([(0,s.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"minScale",void 0),(0,i._)([(0,s.MZ)({type:Number,nonNullable:!0,json:{write:!0}})],t.prototype,"maxScale",void 0),(0,i._)([(0,s.MZ)({readOnly:!0})],t.prototype,"effectiveScaleRange",null),t=(0,i._)([(0,o.$)("esri.layers.mixins.ScaleRangeLayer")],t),t}},58947:(e,t,r)=>{r.d(t,{Xh:()=>Z,w6:()=>x});var i=r(90237),s=r(78888),o=r(49186),n=r(53966),a=r(74887),l=r(84952),u=r(10107),d=(r(44208),r(87811),r(36005)),p=r(40608),c=r(43937),h=r(46130),y=r(5443),f=r(54239),g=r(16930),m=r(60694),v=r(10873),w=r(83898);var S=r(20655),_=r(80812),b=r(88788),I=r(91682),A=r(26121);const x=e=>{let t=class extends e{constructor(){super(...arguments),this.spatialReference=null,this.fullExtent=null,this.heightModelInfo=null,this.minScale=0,this.maxScale=0,this.version={major:Number.NaN,minor:Number.NaN,versionString:""},this.copyright=null,this.sublayerTitleMode="item-title",this.title=null,this.layerId=null,this.indexInfo=null,this._debouncedSaveOperations=(0,a.sg)((async(e,t,r)=>{switch(e){case Z.SAVE:return this._save(t);case Z.SAVE_AS:return this._saveAs(r,t)}}))}readSpatialReference(e,t){return P(t)}readFullExtent(e,t,r){if(null!=e&&"object"==typeof e){const i=null==e.spatialReference?{...e,spatialReference:P(t)}:e;return y.A.fromJSON(i,r)}const i=t.store,s=P(t);return null==s||null==i?.extent||!Array.isArray(i.extent)||i.extent.some((e=>e<M))?null:new y.A({xmin:i.extent[0],ymin:i.extent[1],xmax:i.extent[2],ymax:i.extent[3],spatialReference:s})}parseVersionString(e){const t={major:Number.NaN,minor:Number.NaN,versionString:e},r=e.split(".");return r.length>=2&&(t.major=parseInt(r[0],10),t.minor=parseInt(r[1],10)),t}readVersion(e,t){const r=t.store,i=null!=r.version?r.version.toString():"";return this.parseVersionString(i)}readTitlePortalItem(e){return"item-title"!==this.sublayerTitleMode?void 0:e}readTitleService(e,t){const r=this.portalItem?.title;if("item-title"===this.sublayerTitleMode)return this.url?(0,m.yG)(this.url,t.name):t.name;let i=t.name;if(!i&&this.url){const e=(0,m.qg)(this.url);null!=e&&(i=e.title)}return"item-title-and-service-name"===this.sublayerTitleMode&&r&&(i=r+" - "+i),(0,m.cr)(i)}set url(e){if(null==e)return void this._set("url",e);const t=(0,m.HZ)({layer:this,url:e,nonStandardUrlAllowed:!1,logger:n.A.getLogger(this)});this._set("url",t.url),null!=t.layerId&&this._set("layerId",t.layerId)}writeUrl(e,t,r,i){(0,m.LS)(this,e,"layers",t,i)}get parsedUrl(){const e=this._get("url"),t=(0,l.An)(e);return t&&null!=this.layerId&&(t.path=`${t.path}/layers/${this.layerId}`),t}async _fetchIndexAndUpdateExtent(e,t){this.indexInfo=(0,w.F)(this.parsedUrl?.path??"",this.rootNode,e,this.customParameters,this.apiKey,n.A.getLogger(this),t),null==this.fullExtent||this.fullExtent.hasZ||this._updateExtent(await this.indexInfo)}_updateExtent(e){if("page"===e?.type){const t=e.rootIndex%e.pageSize,r=e.rootPage?.nodes?.[t];if(null==r?.obb?.center||null==r.obb.halfSize)throw new o.A("sceneservice:invalid-node-page","Invalid node page.");if(r.obb.center[0]<M||null==this.fullExtent||this.fullExtent.hasZ)return;const i=r.obb.halfSize,s=r.obb.center[2],n=Math.sqrt(i[0]*i[0]+i[1]*i[1]+i[2]*i[2]);this.fullExtent.zmin=s-n,this.fullExtent.zmax=s+n}else if("node"===e?.type){const t=e.rootNode?.mbs;if(!Array.isArray(t)||4!==t.length||t[0]<M)return;const r=t[2],i=t[3],{fullExtent:s}=this;s&&(s.zmin=r-i,s.zmax=r+i)}}async _fetchService(e){if(null==this.url)throw new o.A("sceneservice:url-not-set","Scene service can not be loaded without valid portal item or url");if(null==this.layerId&&/SceneServer\/*$/i.test(this.url)){const t=await this._fetchFirstLayerId(e);null!=t&&(this.layerId=t)}return this._fetchServiceLayer(e)}async _fetchFirstLayerId(e){const t=await(0,s.A)(this.url??"",{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e});if(t.data&&Array.isArray(t.data.layers)&&t.data.layers.length>0)return t.data.layers[0].id}async _fetchServiceLayer(e){const t=await(0,s.A)(this.parsedUrl?.path??"",{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e});t.ssl&&this.url&&(this.url=this.url.replace(/^http:/i,"https:"));let r=!1;if(t.data.layerType&&"Voxel"===t.data.layerType&&(r=!0),r)return this._fetchVoxelServiceLayer();const i=t.data;this.read(i,this._getServiceContext()),this.validateLayer(i)}async _fetchVoxelServiceLayer(e){const t=(await(0,s.A)(this.parsedUrl?.path+"/layer",{query:{f:"json",...this.customParameters,token:this.apiKey},responseType:"json",signal:e})).data;this.read(t,this._getServiceContext()),this.validateLayer(t)}_getServiceContext(){return{origin:"service",portalItem:this.portalItem,portal:this.portalItem?.portal,url:this.parsedUrl}}async _ensureLoadBeforeSave(){await this.load(),"beforeSave"in this&&"function"==typeof this.beforeSave&&await this.beforeSave()}validateLayer(e){}async _saveAs(e,t){const r={...F,...t};let i=_.default.from(e);if(!i)throw new o.A("sceneservice:portal-item-required","_saveAs() requires a portal item to save to");i.id&&(i=i.clone(),i.id=null);const s=i.portal||S.A.getDefault();await this._ensureLoadBeforeSave(),i.type=E,i.portal=s;const n=(0,b.m)(i,"portal-item",!0),a={layers:[this.write({},n)]};return await Promise.all(n.resources.pendingOperations??[]),await this._validateAgainstJSONSchema(a,n,r),this.url&&(i.url=this.url),i.title||(i.title=this.title),R(i,r,O.newItem),await s.signIn(),await s.user.addItem({item:i,folder:r?.folder,data:a}),await(0,I.r)(this.resourceReferences,n),this.portalItem=i,(0,h.v)(n),n.portalItem=i,i}async _save(e){const t={...F,...e};if(!this.portalItem)throw new o.A("sceneservice:portal-item-not-set","Portal item to save to has not been set on this SceneService");if(this.portalItem.type!==E)throw new o.A("sceneservice:portal-item-wrong-type",`Portal item needs to have type "${E}"`);await this._ensureLoadBeforeSave();const r=(0,b.m)(this.portalItem,"portal-item",!0),i={layers:[this.write({},r)]};return await Promise.all(r.resources.pendingOperations??[]),await this._validateAgainstJSONSchema(i,r,t),this.url&&(this.portalItem.url=this.url),this.portalItem.title||(this.portalItem.title=this.title),R(this.portalItem,t,O.existingItem),await(0,I.S)(this.portalItem,i,this.resourceReferences,r),(0,h.v)(r),this.portalItem}async _validateAgainstJSONSchema(e,t,r){const i=r?.validationOptions;(0,A.c)(t,{errorName:"sceneservice:save"},{ignoreUnsupported:i?.ignoreUnsupported,supplementalUnsupportedErrors:["scenemodification:unsupported"]});const s=i?.enabled,a=null;if(s&&a){const t=(await a()).validate(e,r.portalItemLayerType);if(!t.length)return;const s=`Layer item did not validate:\n${t.join("\n")}`;if(n.A.getLogger(this).error(`_validateAgainstJSONSchema(): ${s}`),"throw"===i.failPolicy){const e=t.map((e=>new o.A("sceneservice:schema-validation",e)));throw new o.A("sceneservice-validate:error","Failed to save layer item due to schema validation, see `details.errors`.",{validationErrors:e})}}}};return(0,i._)([(0,u.MZ)(v.id)],t.prototype,"id",void 0),(0,i._)([(0,u.MZ)({type:g.A})],t.prototype,"spatialReference",void 0),(0,i._)([(0,d.w)("spatialReference",["spatialReference","store.indexCRS","store.geographicCRS"])],t.prototype,"readSpatialReference",null),(0,i._)([(0,u.MZ)({type:y.A})],t.prototype,"fullExtent",void 0),(0,i._)([(0,d.w)("fullExtent",["fullExtent","store.extent","spatialReference","store.indexCRS","store.geographicCRS"])],t.prototype,"readFullExtent",null),(0,i._)([(0,u.MZ)({readOnly:!0,type:f.A})],t.prototype,"heightModelInfo",void 0),(0,i._)([(0,u.MZ)({type:Number,json:{name:"layerDefinition.minScale",write:!0,origins:{service:{read:{source:"minScale"},write:!1}}}})],t.prototype,"minScale",void 0),(0,i._)([(0,u.MZ)({type:Number,json:{name:"layerDefinition.maxScale",write:!0,origins:{service:{read:{source:"maxScale"},write:!1}}}})],t.prototype,"maxScale",void 0),(0,i._)([(0,u.MZ)({readOnly:!0})],t.prototype,"version",void 0),(0,i._)([(0,d.w)("version",["store.version"])],t.prototype,"readVersion",null),(0,i._)([(0,u.MZ)({type:String,json:{read:{source:"copyrightText"}}})],t.prototype,"copyright",void 0),(0,i._)([(0,u.MZ)({type:String,json:{read:!1}})],t.prototype,"sublayerTitleMode",void 0),(0,i._)([(0,u.MZ)({type:String})],t.prototype,"title",void 0),(0,i._)([(0,d.w)("portal-item","title")],t.prototype,"readTitlePortalItem",null),(0,i._)([(0,d.w)("service","title",["name"])],t.prototype,"readTitleService",null),(0,i._)([(0,u.MZ)({type:Number,json:{origins:{service:{read:{source:"id"}},"portal-item":{write:{target:"id",isRequired:!0,ignoreOrigin:!0},read:!1}}}})],t.prototype,"layerId",void 0),(0,i._)([(0,u.MZ)(v.OZ)],t.prototype,"url",null),(0,i._)([(0,c.K)("url")],t.prototype,"writeUrl",null),(0,i._)([(0,u.MZ)()],t.prototype,"parsedUrl",null),(0,i._)([(0,u.MZ)({readOnly:!0})],t.prototype,"store",void 0),(0,i._)([(0,u.MZ)({type:String,readOnly:!0,json:{read:{source:"store.rootNode"}}})],t.prototype,"rootNode",void 0),t=(0,i._)([(0,p.$)("esri.layers.mixins.SceneService")],t),t},M=-1e38;function P(e){if(null!=e.spatialReference)return g.A.fromJSON(e.spatialReference);const t=e.store,r=t.indexCRS||t.geographicCRS,i=r&&parseInt(r.slice(r.lastIndexOf("/")+1),10);return null!=i?new g.A(i):null}function R(e,t,r){e.typeKeywords||(e.typeKeywords=[]);const i=t.getTypeKeywords();for(const t of i)e.typeKeywords.push(t);e.typeKeywords&&(e.typeKeywords=e.typeKeywords.filter(((e,t,r)=>r.indexOf(e)===t)),r===O.newItem&&(e.typeKeywords=e.typeKeywords.filter((e=>"Hosted Service"!==e))))}var O,U;(U=O||(O={}))[U.existingItem=0]="existingItem",U[U.newItem=1]="newItem";const E="Scene Service",F={getTypeKeywords:()=>[],portalItemLayerType:"unknown",validationOptions:{enabled:!0,ignoreUnsupported:!1,failPolicy:"throw"}};var Z;!function(e){e[e.SAVE=0]="SAVE",e[e.SAVE_AS=1]="SAVE_AS"}(Z||(Z={}))},83898:(e,t,r)=>{r.d(t,{F:()=>o});var i=r(78888),s=r(49186);async function o(e,t,r,o,n,a,l){let u=null;if(null!=r){const t=`${e}/nodepages/`,s=t+Math.floor(r.rootIndex/r.nodesPerPage);try{return{type:"page",rootPage:(await(0,i.A)(s,{query:{f:"json",...o,token:n},responseType:"json",signal:l})).data,rootIndex:r.rootIndex,pageSize:r.nodesPerPage,lodMetric:r.lodSelectionMetricType,urlPrefix:t}}catch(e){null!=a&&a.warn("#fetchIndexInfo()","Failed to load root node page. Falling back to node documents.",s,e),u=e}}if(!t)return null;const d=t?.split("/").pop(),p=`${e}/nodes/`,c=p+d;try{return{type:"node",rootNode:(await(0,i.A)(c,{query:{f:"json",...o,token:n},responseType:"json",signal:l})).data,urlPrefix:p}}catch(e){throw new s.A("sceneservice:root-node-missing","Root node missing.",{pageError:u,nodeError:e,url:c})}}},17036:(e,t,r)=>{r.d(t,{p:()=>l});var i=r(44208),s=r(53966),o=r(20437),n=r(95466),a=r(30524);function l(){return{fields:{type:[o.A],value:null,set:function(e){if(e&&(0,i.A)("big-integer-warning-enabled")){const t=e.filter((e=>"big-integer"===e.type||"oid"===e.type&&(e.length||0)>=8));if(t.length){const e=t.map((e=>`'${e.name}'`)).join(", ");s.A.getLogger(this).warn("#fields",`Layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}') references big-integer field(s): ${e}, support for which is experimental. Only integers less than ${Number.MAX_SAFE_INTEGER} (Number.MAX_SAFE_INTEGER) are supported.`)}}this._set("fields",e)}},fieldsIndex:{readOnly:!0,get(){return n.A.fromLayer(this)}},outFields:{type:[String],json:{read:!1},set:function(e){this._userOutFields=e,this.notifyChange("outFields")},get:function(){const e=this._userOutFields;if(!e?.length)return null;if(e.includes("*"))return["*"];if(!this.fields)return e;for(const t of e){const r=this.fieldsIndex?.has(t);r||s.A.getLogger("esri.layers.support.fieldProperties").error("field-attributes-layer:invalid-field",`Invalid field ${t} found in outFields`,{layer:this,outFields:e})}return(0,a.DB)(this.fieldsIndex,e)}}}}},88788:(e,t,r)=>{r.d(t,{m:()=>n,v:()=>o});var i=r(84952),s=r(20655);function o(e,t){return{...a(e,t),readResourcePaths:[]}}function n(e,t,r){const s=(0,i.An)(e.itemUrl);return{...a(e,t),messages:[],writtenProperties:[],blockedRelativeUrls:[],verifyItemRelativeUrls:s?{rootPath:s.path,writtenUrls:[]}:null,resources:r?{toAdd:[],toUpdate:[],toKeep:[],pendingOperations:[]}:null}}function a(e,t){return{origin:t,url:(0,i.An)(e.itemUrl),portal:e.portal||s.A.getDefault(),portalItem:e}}},15804:(e,t,r)=>{r.d(t,{addOrUpdateResources:()=>a,bg:()=>c,cL:()=>p,fetchResources:()=>n,removeAllResources:()=>u,removeResource:()=>l});var i=r(78888),s=r(49186),o=r(84952);async function n(e,t={},r){await e.load(r);const i=(0,o.fj)(e.itemUrl,"resources"),{start:s=1,num:n=10,sortOrder:a="asc",sortField:l="resource"}=t,u={query:{start:s,num:n,sortOrder:a,sortField:l,token:e.apiKey},signal:r?.signal},d=await e.portal.request(i,u);return{total:d.total,nextStart:d.nextStart,resources:d.resources.map((({created:t,size:r,resource:i})=>({created:new Date(t),size:r,resource:e.resourceFromPath(i)})))}}async function a(e,t,r,i){const n=new Map;for(const{resource:e,content:i,compress:o,access:a}of t){if(!e.hasPath())throw new s.A(`portal-item-resource-${r}:invalid-path`,"Resource does not have a valid path");const[t,l]=d(e.path),u=`${t}/${o??""}/${a??""}`;n.has(u)||n.set(u,{prefix:t,compress:o,access:a,files:[]}),n.get(u).files.push({fileName:l,content:i})}await e.load(i);const a=(0,o.fj)(e.userItemUrl,"add"===r?"addResources":"updateResources");for(const{prefix:t,compress:r,access:s,files:o}of n.values()){const n=25;for(let l=0;l<o.length;l+=n){const u=o.slice(l,l+n),d=new FormData;t&&"."!==t&&d.append("resourcesPrefix",t),r&&d.append("compress","true"),s&&d.append("access",s);let p=0;for(const{fileName:e,content:t}of u)d.append("file"+ ++p,t,e);d.append("f","json"),await e.portal.request(a,{method:"post",body:d,signal:i?.signal})}}}async function l(e,t,r){if(!t.hasPath())throw new s.A("portal-item-resources-remove:invalid-path","Resource does not have a valid path");await e.load(r);const i=(0,o.fj)(e.userItemUrl,"removeResources");await e.portal.request(i,{method:"post",query:{resource:t.path},signal:r?.signal}),t.portalItem=null}async function u(e,t){await e.load(t);const r=(0,o.fj)(e.userItemUrl,"removeResources");return e.portal.request(r,{method:"post",query:{deleteAll:!0},signal:t?.signal})}function d(e){const t=e.lastIndexOf("/");return-1===t?[".",e]:[e.slice(0,t),e.slice(t+1)]}async function p(e){return"blob"===e.type?e.blob:"json"===e.type?new Blob([e.jsonString],{type:"application/json"}):(await(0,i.A)(e.url,{responseType:"blob"})).data}function c(e,t){if(!e.hasPath())return null;const[r,,i]=function(e){const[t,r]=function(e){const t=(0,o.Zo)(e);return null==t?[e,""]:[e.slice(0,e.length-t.length-1),`.${t}`]}(e),[i,s]=d(t);return[i,s,r]}(e.path);return e.portalItem.resourceFromPath((0,o.fj)(r,t+i))}},24212:(e,t,r)=>{function i(e,t){return function(e,t){return t?.mode?t.mode:function(e){return e?l:u}(e).mode}(null==e||(e.hasZ??!1),t)}function s(e,t,r){return r&&r.mode!==t?`${e} only support ${t} elevation mode`:null}function o(e,t,r){return r?.mode===t?`${e} do not support ${t} elevation mode`:null}function n(e,t){return null!=t?.featureExpressionInfo&&"0"!==t.featureExpressionInfo.expression?`${e} do not support featureExpressionInfo`:null}function a(e,t){t&&e.warn(".elevationInfo=",t)}r.d(t,{$7:()=>o,B:()=>s,XF:()=>a,tW:()=>n,w7:()=>i}),r(83047),r(16271);const l={mode:"absolute-height",offset:0},u={mode:"on-the-ground",offset:null}},30291:(e,t,r)=>{r.d(t,{tn:()=>u});var i=r(13874),s=r(30524),o=r(89893),n=(r(84424),r(80737),r(96808),r(66159)),a=(r(67336),r(92094),r(23721),r(47582),r(41227)),l=r(68780);function u({displayField:e,editFieldsInfo:t,fields:r,objectIdField:l,title:u},h){if(!r)return null;const f=function(e,t){const r=t?.visibleFieldNames;return function({fields:e,ignoreFieldTypes:t,sortDisabled:r}){const i=e;return t&&(e=e.filter((e=>!t.includes(e.type)))),e===i&&(e=e.slice()),!0!==r&&e.sort(p),e}({fields:e.fields??[],ignoreFieldTypes:t?.ignoreFieldTypes||y,sortDisabled:t?.sortDisabled}).map((t=>new a.A({fieldName:t.name,isEditable:(0,s.R$)(t,e),label:t.alias,format:c(t),visible:d(t,{...e,visibleFieldNames:r})})))}({editFieldsInfo:t,fields:r,objectIdField:l},h);if(!f.length)return null;const g=function(e){const t=(0,s.mB)(e),{titleBase:r}=e;return t?`${r}: {${t.trim()}}`:r??""}({titleBase:u,fields:r,displayField:e}),m=[new n.A,new o.A];return new i.A({title:g,content:m,fieldInfos:f})}const d=(e,t)=>t.visibleFieldNames?t.visibleFieldNames.has(e.name):(0,s.Bz)(e,t);function p(e,t){return"oid"===e.type?-1:"oid"===t.type?1:h(e)?-1:h(t)?1:(e.alias||e.name).toLocaleLowerCase().localeCompare((t.alias||t.name).toLocaleLowerCase())}function c(e){switch(e.type){case"small-integer":case"integer":case"single":return new l.A({digitSeparator:!0,places:0});case"double":return new l.A({digitSeparator:!0,places:2});case"string":return(0,s.JL)(e.name)?new l.A({digitSeparator:!0,places:0}):void 0;default:return}}function h(e){if("name"===(e.name&&e.name.toLowerCase()))return!0;const t=e.alias?.toLowerCase();return"name"===t}const y=["geometry","blob","raster","guid","xml"]},91682:(e,t,r)=>{r.d(t,{S:()=>l,r:()=>a});var i=r(49186),s=r(74887),o=r(13069),n=r(15804);async function a(e,t,r){const i=await u(e,t,r);await d(i,t,r)}async function l(e,t,r,i,s){const o=await u(r,i,s);await e.update({data:t}),await d(o,i,s)}async function u(e,t,a){if(!t?.resources)return;const l=t.portalItem===e.portalItem?new Set(e.paths):new Set;e.paths.length=0,e.portalItem=t.portalItem;const u=new Set(t.resources.toKeep.map((e=>e.resource.path))),d=new Set,p=[];u.forEach((t=>{l.delete(t),e.paths.push(t)}));const c=[],h=[],y=[];for(const r of t.resources.toUpdate)if(l.delete(r.resource.path),u.has(r.resource.path)||d.has(r.resource.path)){const{resource:t,content:i,finish:s}=r,a=(0,n.bg)(t,(0,o.lk)());e.paths.push(a.path),c.push({resource:a,content:await(0,n.cL)(i),compress:r.compress}),s&&y.push((()=>s(a)))}else{e.paths.push(r.resource.path),h.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});const t=r.finish;t&&y.push((()=>t(r.resource))),d.add(r.resource.path)}for(const r of t.resources.toAdd)if(e.paths.push(r.resource.path),l.has(r.resource.path))l.delete(r.resource.path);else{c.push({resource:r.resource,content:await(0,n.cL)(r.content),compress:r.compress});const e=r.finish;e&&y.push((()=>e(r.resource)))}if(c.length||h.length){const{addOrUpdateResources:e}=await Promise.resolve().then(r.bind(r,15804));await e(t.portalItem,c,"add",a),await e(t.portalItem,h,"update",a)}if(y.forEach((e=>e())),0===p.length)return l;const f=await(0,s.Ol)(p);if((0,s.Te)(a),f.length>0)throw new i.A("save:resources","Failed to save one or more resources",{errors:f});return l}async function d(e,t,r){if(!e||!t.portalItem)return;const i=[];for(const s of e){const e=t.portalItem.resourceFromPath(s);i.push(e.portalItem.removeResource(e,r))}await(0,s.Lx)(i)}},26121:(e,t,r)=>{r.d(t,{c:()=>n,d:()=>s});var i=r(49186);async function s(e){const t=[];for(const r of e.allLayers)if("beforeSave"in r&&"function"==typeof r.beforeSave){const e=r.beforeSave();e&&t.push(e)}await Promise.allSettled(t)}const o=new Set(["layer:unsupported","property:unsupported","symbol:unsupported","symbol-layer:unsupported","url:unsupported"]);function n(e,t,r){let s=(e.messages??[]).filter((({type:e})=>"error"===e)).map((({name:e,message:t,details:r})=>new i.A(e,t,r)));if(e.blockedRelativeUrls&&(s=s.concat(e.blockedRelativeUrls.map((e=>new i.A("url:unsupported",`Relative url '${e}' is not supported`))))),r){const{ignoreUnsupported:e,supplementalUnsupportedErrors:t=[],requiredPropertyChecksDisabled:i}=r;e&&(s=s.filter((({name:e})=>!(o.has(e)||t.includes(e))))),i&&(s=s.filter((e=>"web-document-write:property-required"!==e.name)))}if(s.length>0)throw new i.A(t.errorName,"Failed to save due to unsupported or invalid content. See 'details.errors' for more detailed information",{errors:s})}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5165,7546,8256],{4902:(e,t,r)=>{r.d(t,{A:()=>u});var i=r(90237),s=r(40608);let o=0;const a=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:Date.now().toString(16)+"-object-"+o++})}};return t=(0,i._)([(0,s.$)("esri.core.Identifiable")],t),t};let n=class extends(a(class{})){};var l;n=(0,i._)([(0,s.$)("esri.core.Identifiable")],n),(l=n||(n={})).IdentifiableMixin=a,l.NumericIdentifiableMixin=e=>{let t=class extends e{constructor(...e){super(...e),Object.defineProperty(this,"uid",{writable:!1,configurable:!1,value:o++})}};return t=(0,i._)([(0,s.$)("esri.core.Identifiable.NumericIdentifiable")],t),t};const u=n},92071:(e,t,r)=>{r.d(t,{P:()=>m,L:()=>b});var i=r(90237),s=r(69622),o=r(76953),a=r(4718),n=r(35666);class l{constructor(){this._propertyOriginMap=new Map,this._originStores=new Array(n.AU),this._values=new Map,this.multipleOriginsSupported=!0}clone(e){const t=new l,r=this._originStores[n.Gr.DEFAULTS];r&&r.forEach(((e,r)=>{t.set(r,(0,a.o8)(e),n.Gr.DEFAULTS)}));for(let r=n.Gr.SERVICE;r<n.AU;r++){const i=this._originStores[r];i&&i.forEach(((i,s)=>{e&&e.has(s)||t.set(s,(0,a.o8)(i),r)}))}return t}get(e,t){const r=void 0===t?this._values:this._originStores[t];return r?r.get(e):void 0}keys(e){const t=null==e?this._values:this._originStores[e];return t?[...t.keys()]:[]}set(e,t,r=n.Gr.USER){let i=this._originStores[r];if(i||(i=new Map,this._originStores[r]=i),i.set(e,t),!this._values.has(e)||this._propertyOriginMap.get(e)<=r){const i=this._values.get(e);return this._values.set(e,t),this._propertyOriginMap.set(e,r),i!==t}return!1}delete(e,t=n.Gr.USER){const r=this._originStores[t];if(!r)return;const i=r.get(e);if(r.delete(e),this._values.has(e)&&this._propertyOriginMap.get(e)===t){this._values.delete(e);for(let r=t-1;r>=0;r--){const t=this._originStores[r];if(t&&t.has(e)){this._values.set(e,t.get(e)),this._propertyOriginMap.set(e,r);break}}}return i}has(e,t){const r=void 0===t?this._values:this._originStores[t];return!!r&&r.has(e)}revert(e,t){for(;t>0&&!this.has(e,t);)--t;const r=this._originStores[t],i=r?.get(e),s=this._values.get(e);return this._values.set(e,i),this._propertyOriginMap.set(e,t),s!==i}originOf(e){return this._propertyOriginMap.get(e)||n.Gr.DEFAULTS}forEach(e){this._values.forEach(e)}}var u=r(45917),p=r(88620),d=r(40608);const c=e=>{let t=class extends e{constructor(...e){super(...e);const t=(0,p.oY)(this),r=t.store,i=new l;t.store=i,(0,o.k)(t,r,i)}read(e,t){(0,u.L)(this,e,t)}getAtOrigin(e,t){const r=h(this),i=(0,n.aB)(t);if("string"==typeof e)return r.get(e,i);const s={};return e.forEach((e=>{s[e]=r.get(e,i)})),s}originOf(e){return(0,n.OL)(this.originIdOf(e))}originIdOf(e){return h(this).originOf(e)}revert(e,t){const r=h(this),i=(0,n.aB)(t),s=(0,p.oY)(this);let o;o="string"==typeof e?"*"===e?r.keys(i):[e]:e,o.forEach((e=>{s.invalidate(e),r.revert(e,i),s.commit(e)}))}};return t=(0,i._)([(0,d.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],t),t};function h(e){return(0,p.oY)(e).store}let y=class extends(c(s.A)){};y=(0,i._)([(0,d.$)("esri.core.ReadOnlyMultiOriginJSONSupport")],y);var g=r(16649),f=r(49422);const v=e=>{let t=class extends e{constructor(...e){super(...e)}clear(e,t="user"){return _(this).delete(e,(0,n.aB)(t))}write(e,t){return(0,f.M)(this,e=e||{},t),e}setAtOrigin(e,t,r){(0,p.oY)(this).setAtOrigin(e,t,(0,n.aB)(r))}removeOrigin(e){const t=_(this),r=(0,n.aB)(e),i=t.keys(r);for(const e of i)t.originOf(e)===r&&t.set(e,t.get(e,r),n.Gr.USER)}updateOrigin(e,t){const r=_(this),i=(0,n.aB)(t),s=(0,g.Jt)(this,e);for(let t=i+1;t<n.AU;++t)r.delete(e,t);r.set(e,s,i)}toJSON(e){return this.write({},e)}};return t=(0,i._)([(0,d.$)("esri.core.MultiOriginJSONSupport.WriteableMultiOriginJSONSupport")],t),t.prototype.toJSON.isDefaultToJSON=!0,t};function _(e){return(0,p.oY)(e).store}const m=e=>{let t=class extends(v(c(e))){constructor(...e){super(...e)}};return t=(0,i._)([(0,d.$)("esri.core.MultiOriginJSONSupport")],t),t};let b=class extends(m(s.A)){};b=(0,i._)([(0,d.$)("esri.core.MultiOriginJSONSupport")],b)},4146:(e,t,r)=>{r.d(t,{A:()=>b});var i=r(90237),s=r(78888),o=r(49186),a=r(65529),n=r(4902),l=r(92474),u=r(53966),p=r(74887),d=r(84952),c=r(10107),h=(r(44208),r(87811),r(40608)),y=r(5443),g=r(16930),f=r(92602),v=r(79677);let _=0,m=class extends(a.A.EventedMixin(n.A.IdentifiableMixin(l.A))){constructor(){super(...arguments),this.attributionDataUrl=null,this.fullExtent=new y.A(-180,-90,180,90,g.A.WGS84),this.id=Date.now().toString(16)+"-layer-"+_++,this.legendEnabled=!0,this.listMode="show",this.opacity=1,this.parent=null,this.persistenceEnabled=!1,this.popupEnabled=!0,this.attributionVisible=!0,this.spatialReference=g.A.WGS84,this.title=null,this.type=null,this.url=null,this.visibilityTimeExtent=null,this.visible=!0,this.createLayerView=void 0}static async fromArcGISServerUrl(e){const t="string"==typeof e?{url:e}:e;return(await r.e(7982).then(r.bind(r,27982))).fromUrl(t)}static fromPortalItem(e){return async function(e){const t="portalItem"in e?e:{portalItem:e},{fromItem:i}=await r.e(5613).then(r.bind(r,45613));try{return await i(t)}catch(e){const r=t?.portalItem,i=r?.id||"unset",s=r?.portal?.url||f.A.portalUrl;throw u.A.getLogger("esri.layers.support.fromPortalItem").error("#fromPortalItem()","Failed to create layer from portal item (portal: '"+s+"', id: '"+i+"')",e),e}}(e)}initialize(){this.when().catch((e=>{(0,p.zf)(e)||u.A.getLogger(this).error("#load()",`Failed to load layer (title: '${this.title??"no title"}', id: '${this.id??"no id"}')`,{error:e})}))}destroy(){const e=this.parent;if(e){const t=this;"layers"in e&&e.layers.includes(t)?e.layers.remove(t):"tables"in e&&e.tables.includes(t)?e.tables.remove(t):"baseLayers"in e&&e.baseLayers.includes(t)?e.baseLayers.remove(t):"referenceLayers"in e&&e.referenceLayers.includes(t)&&e.referenceLayers.remove(t),this._set("parent",null)}}get effectiveVisible(){let e=this.visible;const t=this.parent;return e&&t&&"effectiveVisible"in t&&(e&&=t.effectiveVisible),e}get hasAttributionData(){return null!=this.attributionDataUrl}get parsedUrl(){return(0,d.An)(this.url)}async fetchAttributionData(){const e=this.attributionDataUrl;if(this.hasAttributionData&&e)return(await(0,s.A)(e,{query:{f:"json"},responseType:"json"})).data;throw new o.A("layer:no-attribution-data","Layer does not have attribution data")}};(0,i._)([(0,c.MZ)({type:String})],m.prototype,"attributionDataUrl",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],m.prototype,"effectiveVisible",null),(0,i._)([(0,c.MZ)({type:y.A})],m.prototype,"fullExtent",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],m.prototype,"hasAttributionData",null),(0,i._)([(0,c.MZ)({type:String,clonable:!1})],m.prototype,"id",void 0),(0,i._)([(0,c.MZ)({type:Boolean,nonNullable:!0})],m.prototype,"legendEnabled",void 0),(0,i._)([(0,c.MZ)({type:["show","hide","hide-children"]})],m.prototype,"listMode",void 0),(0,i._)([(0,c.MZ)({type:Number,range:{min:0,max:1},nonNullable:!0})],m.prototype,"opacity",void 0),(0,i._)([(0,c.MZ)({clonable:!1})],m.prototype,"parent",void 0),(0,i._)([(0,c.MZ)({readOnly:!0})],m.prototype,"parsedUrl",null),(0,i._)([(0,c.MZ)({type:Boolean,readOnly:!0})],m.prototype,"persistenceEnabled",void 0),(0,i._)([(0,c.MZ)({type:Boolean})],m.prototype,"popupEnabled",void 0),(0,i._)([(0,c.MZ)({type:Boolean})],m.prototype,"attributionVisible",void 0),(0,i._)([(0,c.MZ)({type:g.A})],m.prototype,"spatialReference",void 0),(0,i._)([(0,c.MZ)({type:String})],m.prototype,"title",void 0),(0,i._)([(0,c.MZ)({readOnly:!0,json:{read:!1}})],m.prototype,"type",void 0),(0,i._)([(0,c.MZ)()],m.prototype,"url",void 0),(0,i._)([(0,c.MZ)({type:v.A})],m.prototype,"visibilityTimeExtent",void 0),(0,i._)([(0,c.MZ)({type:Boolean,nonNullable:!0})],m.prototype,"visible",void 0),m=(0,i._)([(0,h.$)("esri.layers.Layer")],m);const b=m},45165:(e,t,r)=>{r.r(t),r.d(t,{default:()=>c});var i=r(90237),s=r(49186),o=r(92071),a=r(11932),n=r(10107),l=(r(44208),r(53966),r(87811),r(40608)),u=r(4146),p=r(8303);let d=class extends((0,p.A)((0,o.P)(u.A))){constructor(e){super(e),this.resourceInfo=null,this.persistenceEnabled=!0,this.type="unsupported"}initialize(){this.addResolvingPromise(new Promise(((e,t)=>{(0,a._)((()=>{const e=this.resourceInfo&&(this.resourceInfo.layerType||this.resourceInfo.type);let r="Unsupported layer type";e&&(r+=" "+e),t(new s.A("layer:unsupported-layer-type",r,{layerType:e}))}))})))}read(e,t){const r={resourceInfo:e};null!=e.id&&(r.id=e.id),null!=e.title&&(r.title=e.title),super.read(r,t)}write(e,t){return Object.assign(e||{},this.resourceInfo,{id:this.id})}};(0,i._)([(0,n.MZ)({readOnly:!0})],d.prototype,"resourceInfo",void 0),(0,i._)([(0,n.MZ)({type:["show","hide"]})],d.prototype,"listMode",void 0),(0,i._)([(0,n.MZ)({type:Boolean,readOnly:!1})],d.prototype,"persistenceEnabled",void 0),(0,i._)([(0,n.MZ)({json:{read:!1},readOnly:!0,value:"unsupported"})],d.prototype,"type",void 0),d=(0,i._)([(0,l.$)("esri.layers.UnsupportedLayer")],d);const c=d},8303:(e,t,r)=>{r.d(t,{A:()=>w});var i=r(90237),s=r(92602),o=r(70333),a=r(78888),n=r(60999),l=r(49186),u=r(53966),p=r(97768),d=r(74887),c=r(84952),h=r(10107),y=(r(44208),r(87811),r(36005)),g=r(40608),f=r(43937),v=r(83531),_=r(20655),m=r(80812),b=r(41318),I=r(10407);const w=e=>{let t=class extends e{constructor(){super(...arguments),this.resourceReferences={portalItem:null,paths:[]},this.userHasEditingPrivileges=!0,this.userHasFullEditingPrivileges=!1,this.userHasUpdateItemPrivileges=!1}destroy(){this.portalItem=(0,p.pR)(this.portalItem),this.resourceReferences.portalItem=null,this.resourceReferences.paths.length=0}set portalItem(e){e!==this._get("portalItem")&&(this.removeOrigin("portal-item"),this._set("portalItem",e))}readPortalItem(e,t,r){if(t.itemId)return new m.default({id:t.itemId,portal:r?.portal})}writePortalItem(e,t){e?.id&&(t.itemId=e.id)}async loadFromPortal(e,t){if(this.portalItem?.id)try{const{load:i}=await r.e(1204).then(r.bind(r,41204));return(0,d.Te)(t),await i({instance:this,supportedTypes:e.supportedTypes,validateItem:e.validateItem,supportsData:e.supportsData,layerModuleTypeMap:e.layerModuleTypeMap,populateGroupLayer:e.populateGroupLayer},t)}catch(e){throw(0,d.zf)(e)||u.A.getLogger(this).warn(`Failed to load layer (${this.title}, ${this.id}) portal item (${this.portalItem.id})\n ${e}`),e}}async finishLoadEditablePortalLayer(e){this._set("userHasEditingPrivileges",await this._fetchUserHasEditingPrivileges(e).catch((e=>((0,d.QP)(e),!0))))}async setUserPrivileges(e,t){if(!s.A.userPrivilegesApplied)return this.finishLoadEditablePortalLayer(t);if(this.url)try{const{features:{edit:r,fullEdit:i},content:{updateItem:s}}=await this._fetchUserPrivileges(e,t);this._set("userHasEditingPrivileges",r),this._set("userHasFullEditingPrivileges",i),this._set("userHasUpdateItemPrivileges",s)}catch(e){(0,d.QP)(e)}}async _fetchUserPrivileges(e,t){let r=this.portalItem;if(!e||!r||!r.loaded||r.sourceUrl)return this._fetchFallbackUserPrivileges(t);const i=!o.id?.findCredential(this.url),s=e===r.id;if(s&&r.portal.user)return this._getUserPrivileges(r,i);let a,n;if(s)a=r.portal.url;else try{a=await(0,v.wI)(this.url,t)}catch(e){(0,d.QP)(e)}if(!a||!(0,c.b8)(a,r.portal.url))return this._fetchFallbackUserPrivileges(t);try{const e=null!=t?t.signal:null;n=await(o.id?.getCredential(`${a}/sharing`,{prompt:!1,signal:e}))}catch(e){(0,d.QP)(e)}const l=!0,u=!1,p=!1;if(!n)return{features:{edit:l,fullEdit:u},content:{updateItem:p}};try{if(s?await r.reload():(r=new m.default({id:e,portal:{url:a}}),await r.load(t)),r.portal.user)return this._getUserPrivileges(r,i)}catch(e){(0,d.QP)(e)}return{features:{edit:l,fullEdit:u},content:{updateItem:p}}}_getUserPrivileges(e,t){const r=(0,I.It)(e);return t&&(r.features.edit=!0),r}async _fetchFallbackUserPrivileges(e){let t=!0;try{t=await this._fetchUserHasEditingPrivileges(e)}catch(e){(0,d.QP)(e)}return{features:{edit:t,fullEdit:!1},content:{updateItem:!1}}}async _fetchUserHasEditingPrivileges(e){const t=this.url?o.id?.findCredential(this.url):null;if(!t)return!0;const r=M.credential===t?M.user:await this._fetchEditingUser(e);return M.credential=t,M.user=r,null==r?.privileges||r.privileges.includes("features:user:edit")}async _fetchEditingUser(e){const t=this.portalItem?.portal?.user;if(t)return t;const r=o.id?.findServerInfo(this.url??"");if(!r?.owningSystemUrl)return null;const i=`${r.owningSystemUrl}/sharing/rest`,s=_.A.getDefault();if(s&&s.loaded&&(0,c.S8)(s.restUrl)===(0,c.S8)(i))return s.user;const l=`${i}/community/self`,u=null!=e?e.signal:null,p=await(0,n.Ke)((0,a.A)(l,{authMode:"no-prompt",query:{f:"json"},signal:u}));return p.ok?b.A.fromJSON(p.value.data):null}read(e,t){t&&(t.layer=this),super.read(e,t)}write(e,t){const r=t?.portal,i=this.portalItem?.id&&(this.portalItem.portal||_.A.getDefault());return r&&i&&!(0,c.ut)(i.restUrl,r.restUrl)?(t.messages&&t.messages.push(new l.A("layer:cross-portal",`The layer '${this.title} (${this.id})' cannot be persisted because it refers to an item on a different portal than the one being saved to. To save, set layer.portalItem to null or save to the same portal as the item associated with the layer`,{layer:this})),null):super.write(e,{...t,layer:this})}};return(0,i._)([(0,h.MZ)({type:m.default})],t.prototype,"portalItem",null),(0,i._)([(0,y.w)("web-document","portalItem",["itemId"])],t.prototype,"readPortalItem",null),(0,i._)([(0,f.K)("web-document","portalItem",{itemId:{type:String}})],t.prototype,"writePortalItem",null),(0,i._)([(0,h.MZ)({clonable:!1})],t.prototype,"resourceReferences",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasFullEditingPrivileges",void 0),(0,i._)([(0,h.MZ)({type:Boolean,readOnly:!0})],t.prototype,"userHasUpdateItemPrivileges",void 0),t=(0,i._)([(0,g.$)("esri.layers.mixins.PortalLayer")],t),t},M={credential:null,user:null}}}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[9239],{9239:(t,e,o)=>{o.r(e),o.d(e,{executeAttachmentQuery:()=>b,fetchAttachments:()=>j,processAttachmentQueryResult:()=>I});var n,r=o(70333),i=o(78888),a=o(84952),s=o(10536),l=o(90237),d=o(25482),p=o(10107),c=o(56507),u=(o(44208),o(87811),o(40608));const h={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 f=n=class extends d.A{constructor(t){super(t),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:t}=this,e=function(t){const{exifInfo:e,exifName:o,tagName:n}=t;if(!e||!o||!n)return null;const r=e.find((t=>t.name===o));return r?function(t){const{tagName:e,tags:o}=t;if(!o||!e)return null;const n=o.find((t=>t.name===e));return n?.value||null}({tagName:n,tags:r.tags}):null}({exifName:"Exif IFD0",tagName:"Orientation",exifInfo:t});return h[e]||null}clone(){return new n({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,l._)([(0,p.MZ)({type:String})],f.prototype,"contentType",void 0),(0,l._)([(0,p.MZ)()],f.prototype,"exifInfo",void 0),(0,l._)([(0,p.MZ)({readOnly:!0})],f.prototype,"orientationInfo",null),(0,l._)([(0,p.MZ)({type:c.jz})],f.prototype,"id",void 0),(0,l._)([(0,p.MZ)({type:String})],f.prototype,"globalId",void 0),(0,l._)([(0,p.MZ)({type:String})],f.prototype,"keywords",void 0),(0,l._)([(0,p.MZ)({type:String})],f.prototype,"name",void 0),(0,l._)([(0,p.MZ)({json:{read:!1}})],f.prototype,"parentGlobalId",void 0),(0,l._)([(0,p.MZ)({json:{read:!1}})],f.prototype,"parentObjectId",void 0),(0,l._)([(0,p.MZ)({type:c.jz})],f.prototype,"size",void 0),(0,l._)([(0,p.MZ)({json:{read:!1}})],f.prototype,"url",void 0),f=n=(0,l._)([(0,u.$)("esri.rest.query.support.AttachmentInfo")],f);const y=f;function m(t){const e=t.toJSON();return e.attachmentTypes&&(e.attachmentTypes=e.attachmentTypes.join(",")),e.keywords&&(e.keywords=e.keywords.join(",")),e.globalIds&&(e.globalIds=e.globalIds.join(",")),e.objectIds&&(e.objectIds=e.objectIds.join(",")),e.size&&(e.size=e.size.join(",")),e}function I(t,e){const o={};for(const n of e){const{parentObjectId:e,parentGlobalId:i,attachmentInfos:s}=n;for(const n of s){const{id:s}=n,l=(0,a.yM)((0,r.Y3)(`${t.path}/${e}/attachments/${s}`)),d=y.fromJSON(n);d.set({url:l,parentObjectId:e,parentGlobalId:i}),o[e]?o[e].push(d):o[e]=[d]}}return o}function b(t,e,o){let n={query:(0,s.z)({...t.query,f:"json",...m(e)})};return o&&(n={...o,...n,query:{...o.query,...n.query}}),(0,i.A)(t.path+"/queryAttachments",n).then((t=>t.data.attachmentGroups))}async function j(t,e,o){const{objectIds:n}=e,r=[];for(const e of n)r.push((0,i.A)(t.path+"/"+e+"/attachments",o));return Promise.all(r).then((t=>n.map(((e,o)=>({parentObjectId:e,attachmentInfos:t[o].data.attachmentInfos})))))}}}]);
|