@arcgis/core 4.34.0-next.21 → 4.34.0-next.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/applications/Components/arcadeFeatureUtils.d.ts +5 -0
- package/applications/Components/arcadeFeatureUtils.js +5 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{bcaf6edf887e4afbbdd2.js → 02dc6e31b1244e5bb785.js} +1 -1
- package/assets/esri/core/workers/chunks/{871fae52d2fddc9e7794.js → 04c17957c15234ca0321.js} +1 -1
- package/assets/esri/core/workers/chunks/084236ca316aad980192.js +1 -0
- package/assets/esri/core/workers/chunks/0b484224a92b52c34330.js +1 -0
- package/assets/esri/core/workers/chunks/{822b32aaeec05a347c84.js → 0ba6177ba118a0f032e2.js} +1 -1
- package/assets/esri/core/workers/chunks/0f6203ae32663b2b52db.js +1 -0
- package/assets/esri/core/workers/chunks/12723e79b996969e304e.js +1 -0
- package/assets/esri/core/workers/chunks/{bd7b985f7962b1cc7b8a.js → 146520d263b910b5bdc7.js} +1 -1
- package/assets/esri/core/workers/chunks/{445ddf57d2f503a0b98b.js → 15064c3b21b325d5c2f6.js} +1 -1
- package/assets/esri/core/workers/chunks/19ae76283a0cb0fe4dee.js +346 -0
- package/assets/esri/core/workers/chunks/{82a5000296134834d1ac.js → 1d75cb1747ffb7b8b050.js} +1 -1
- package/assets/esri/core/workers/chunks/20bcd2e6cf02e057ad7d.js +1 -0
- package/assets/esri/core/workers/chunks/{55ce214a10fb6fc2e901.js → 24fe862b607ec927e07f.js} +1 -1
- package/assets/esri/core/workers/chunks/30fae1f066dc3cd781f1.js +1 -0
- package/assets/esri/core/workers/chunks/{7ec73f63929b1623de72.js → 3793f282ddaccd3465f2.js} +1 -1
- package/assets/esri/core/workers/chunks/3fcd73ba832cb53d3a07.js +1 -0
- package/assets/esri/core/workers/chunks/{5e7f35bf1aab93cb1c52.js → 4cea5170939c8d363ef7.js} +1 -1
- package/assets/esri/core/workers/chunks/5253cca467fe9bc0a210.js +1 -0
- package/assets/esri/core/workers/chunks/{735d96d2b951cc1df3a3.js → 576e408fb0834f3948e8.js} +1 -1
- package/assets/esri/core/workers/chunks/{27c9d3f6cebca087a123.js → 6136bf09950adc46bc33.js} +1 -1
- package/assets/esri/core/workers/chunks/{dfd9ac2e28c96900c53e.js → 6c33ecffbc783cb8f944.js} +1 -1
- package/assets/esri/core/workers/chunks/6ca764b4baadef5c1515.js +1 -0
- package/assets/esri/core/workers/chunks/{fcdf714339060731fe1c.js → 7051bcc178eb512819f6.js} +1 -1
- package/assets/esri/core/workers/chunks/7cfba5cec425221962e8.js +1 -0
- package/assets/esri/core/workers/chunks/{3a753ce4de2e6ad40f7b.js → 86d6007c45f2aa643ac8.js} +1 -1
- package/assets/esri/core/workers/chunks/92ad9098006568358550.js +1 -0
- package/assets/esri/core/workers/chunks/{2ed698579befe73caafd.js → 94d75f3b215e3bd1b4d7.js} +1 -1
- package/assets/esri/core/workers/chunks/{15d1ab71aaf6bcf3145b.js → a7a5b89c2bb69f3af59c.js} +1 -1
- package/assets/esri/core/workers/chunks/{1d9e44bdd129cc682ae5.js → ac93b3f1ff15a95d926c.js} +1 -1
- package/assets/esri/core/workers/chunks/b4512d62b6cb26fc6b25.js +1 -0
- package/assets/esri/core/workers/chunks/{63e984a65ee670449a4a.js → b4bb461955a4c2bce072.js} +1 -1
- package/assets/esri/core/workers/chunks/{abc75c945f3cfb1629b0.js → ba5b24beebeb703b5919.js} +1 -1
- package/assets/esri/core/workers/chunks/{51afd0e71df1825d7593.js → c64fa94cba71ba2794e2.js} +1 -1
- package/assets/esri/core/workers/chunks/c94cc026c4ed330408fb.js +1 -0
- package/assets/esri/core/workers/chunks/cab1a1067f44ce374673.js +1 -0
- package/assets/esri/core/workers/chunks/{3f4a8c874c022dace9be.js → d1b363c418a67b087306.js} +1 -1
- package/assets/esri/core/workers/chunks/d45383d76ba99718b6d9.js +1 -0
- package/assets/esri/core/workers/chunks/{8b19fe829a9dc26fb3fe.js → d915d0a30d9beb24bd3a.js} +1 -1
- package/assets/esri/core/workers/chunks/{bbca1b85656d9ba71e4c.js → def8a854a05f17d3538e.js} +1 -1
- package/assets/esri/core/workers/chunks/{273ff53a68714e4daad5.js → e49a135a2933306a6105.js} +1 -1
- package/assets/esri/core/workers/chunks/{d31fa648497b0af97dc1.js → e9a9174c4d1a0a9effb6.js} +1 -1
- package/assets/esri/core/workers/chunks/f3d5d92e0aefc2593208.js +1 -0
- package/assets/esri/core/workers/chunks/{fc8bbc571216edd9ef5a.js → f3e3c2340452c1d60c95.js} +1 -1
- package/assets/esri/core/workers/chunks/{85b0e2a898251d048dda.js → f42155b7a4e6c5e80757.js} +1 -1
- package/assets/esri/core/workers/chunks/f43110391f124b8a179c.js +1009 -0
- package/assets/esri/core/workers/chunks/f90573c9dc36e51cd588.js +1 -0
- package/assets/esri/core/workers/chunks/{080a8a1c6fe2d215142d.js → fb5e2b1ced03eef28e96.js} +1 -1
- package/assets/esri/core/workers/chunks/fe73e74e3e4278aedcc3.js +1 -0
- package/config.js +1 -1
- package/core/Clonable.js +1 -1
- package/core/lang.js +1 -1
- package/geometry/Mesh.js +1 -1
- package/geometry/support/MeshComponent.js +1 -1
- package/geometry/support/MeshMaterial.js +1 -1
- package/geometry/support/MeshMaterialMetallicRoughness.js +1 -1
- package/geometry/support/MeshTexture.js +1 -1
- package/geometry/support/MeshTransform.js +1 -1
- package/geometry/support/MeshVertexAttributes.js +1 -1
- package/geometry/support/meshUtils/convertMeshVertexSpace.js +1 -1
- package/geometry/support/meshUtils/merge.js +1 -1
- package/geometry/support/meshUtils/meshCloneUtils.js +5 -0
- package/interfaces.d.ts +183 -41
- package/kernel.js +1 -1
- package/layers/VideoLayer.js +1 -1
- package/layers/support/SceneModification.js +1 -1
- package/layers/support/SceneModifications.js +1 -1
- package/layers/support/rasterDatasets/MRFRaster.js +1 -1
- package/layers/video/videoUtils.js +1 -1
- package/libs/basisu/BasisUEncoder.js +1 -1
- package/libs/dxtEncoder/DXTEncoder.js +1 -1
- package/libs/i3s/I3SModule.js +1 -1
- package/networks/support/utils.js +1 -1
- package/package.json +1 -1
- package/rest/knowledgeGraph/GraphAddFieldIndexResult.js +1 -1
- package/rest/knowledgeGraph/GraphAddNamedTypesResult.js +1 -1
- package/rest/knowledgeGraph/GraphAddPropertyResult.js +1 -1
- package/rest/knowledgeGraph/GraphDataModelOperationResult.d.ts +1 -1
- package/rest/knowledgeGraph/GraphDataModelOperationResult.js +1 -1
- package/rest/knowledgeGraph/GraphDeleteFieldIndexResult.js +1 -1
- package/rest/knowledgeGraph/GraphDeleteNamedTypeResult.js +1 -1
- package/rest/knowledgeGraph/GraphDeletePropertyResult.js +1 -1
- package/rest/knowledgeGraph/GraphUpdateNamedTypesResult.js +1 -1
- package/rest/knowledgeGraph/GraphUpdatePropertyResult.js +1 -1
- package/rest/knowledgeGraph/GraphUpdateSearchIndexResult.js +1 -1
- package/support/revision.js +1 -1
- package/views/2d/layers/VideoLayerView2D.js +1 -1
- package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
- package/views/3d/layers/SceneLayerWorker.js +1 -1
- package/views/3d/state/GoToOperation.js +1 -1
- package/views/3d/state/ViewStateManager.js +1 -1
- package/views/3d/support/cameraUtils.js +1 -1
- package/views/3d/support/viewingModeUtils.js +5 -0
- package/views/3d/support/viewpointUtils.js +1 -1
- package/views/3d/terrain/OverlayFramebufferObject.js +1 -1
- package/views/3d/terrain/OverlayManager.js +1 -1
- package/views/3d/terrain/OverlayRenderTargets.js +1 -1
- package/views/3d/terrain/OverlayRenderer.js +1 -1
- package/views/3d/webgl/ManagedFBOResource.js +1 -1
- package/views/3d/webgl.d.ts +2 -0
- package/views/3d/webgl.js +1 -1
- package/views/VideoView.js +1 -1
- package/views/draw/DrawScreenTool.js +1 -1
- package/views/support/TextureCompressionHelper.js +1 -1
- package/views/support/TextureCompressionWorker.js +1 -1
- package/views/support/TextureCompressionWorkerHandle.js +1 -1
- package/views/support/layerViewUtils.js +1 -1
- package/widgets/BatchAttributeForm/inputs/EditableInput.js +1 -1
- package/widgets/BatchAttributeForm/inputs/GroupInput.js +1 -1
- package/widgets/BatchAttributeForm/inputs/InputBase.d.ts +1 -1
- package/widgets/BatchAttributeForm/inputs/InputBase.js +1 -1
- package/widgets/Editor/Edits.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/OrientedImageryViewer.js +1 -1
- package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeature.js +1 -1
- package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeaturesDrillIn.js +1 -1
- package/widgets/UtilityNetworkTrace/UtilityNetworkTraceViewModel.js +1 -1
- package/widgets/support/Selector2D/SelectionOperation.js +1 -1
- package/widgets/support/UtilityNetworkAssociations/FeatureUtilityNetworkAssociationsViewModel.js +1 -1
- package/assets/esri/core/workers/chunks/06c3725d6cc21e7e4bcf.js +0 -1
- package/assets/esri/core/workers/chunks/0f5643d5437f48c63225.js +0 -1
- package/assets/esri/core/workers/chunks/1c7393bcd6e85ba25e1b.js +0 -1
- package/assets/esri/core/workers/chunks/2a784da5fa3f502d1803.js +0 -1
- package/assets/esri/core/workers/chunks/2e3f620c79ec04033a6e.js +0 -1
- package/assets/esri/core/workers/chunks/48953ddf0bbcf3d77e04.js +0 -1
- package/assets/esri/core/workers/chunks/5b7464137aacf1c5fd78.js +0 -1
- package/assets/esri/core/workers/chunks/7925e8ffa8027b59410e.js +0 -1
- package/assets/esri/core/workers/chunks/8235a997acb45ab43173.js +0 -1
- package/assets/esri/core/workers/chunks/8fa6c938e8dc7bbfaeb7.js +0 -1
- package/assets/esri/core/workers/chunks/9d2cb559dd9af4e1727c.js +0 -1
- package/assets/esri/core/workers/chunks/9eb1a171f5ef1fef42ed.js +0 -346
- package/assets/esri/core/workers/chunks/bac5e1d50b69f0d94694.js +0 -1
- package/assets/esri/core/workers/chunks/bcefb413d03d59506b5a.js +0 -1009
- package/assets/esri/core/workers/chunks/c317819ab0544c50c078.js +0 -1
- package/assets/esri/core/workers/chunks/c96fed4889712f5a9135.js +0 -1
- package/assets/esri/core/workers/chunks/cb4c49d5b70f9563bc46.js +0 -1
- package/assets/esri/core/workers/chunks/e9aa1d9ded8a52a40c57.js +0 -1
- package/assets/esri/core/workers/chunks/f65ad6a41c0c69bf1b21.js +0 -1
- package/assets/esri/core/workers/chunks/f806e9221dff7fcfc2f9.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3379],{11764:(e,t,s)=>{s.r(t),s.d(t,{default:()=>ee});var i=s(74887),n=s(89640),r=s(6774),a=s(83027),o=s(13195);function l(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 h(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 c(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 u(e){switch(e){case 9:case 10:case 11:case 12:case 13:case 32:return!0}return!1}var f=s(18989);const d=24;class g{constructor(e,t,s,i,n,r,a){this._glyphItems=e,this._maxWidth=t,this._lineHeight=s,this._letterSpacing=i,this._hAnchor=n,this._vAnchor=r,this._justify=a}getShaping(e,t,s){const i=this._letterSpacing,n=this._lineHeight,r=this._justify,a=this._maxWidth,o=[];let f=0,d=0;for(const t of e){const e=t.codePointAt(0);if(null==e)continue;const n=s&&l(e);let r;for(const t of this._glyphItems)if(r=t[e],r)break;o.push({codePoint:e,x:f,y:d,vertical:n,glyphMosaicItem:r}),r&&(f+=r.metrics.advance+i)}let g=f;a>0&&(g=f/Math.max(1,Math.ceil(f/a)));const p=e.includes(""),y=[],x=o.length;for(let e=0;e<x-1;e++){const t=o[e].codePoint,s=h(t);if(c(t)||s){let i=0;if(10===t)i-=1e4;else if(s&&p)i+=150;else{40!==t&&65288!==t||(i+=50);const s=o[e+1].codePoint;41!==s&&65289!==s||(i+=50)}y.push(this._buildBreak(e+1,o[e].x,g,y,i,!1))}}const _=this._optimalBreaks(this._buildBreak(x,f,g,y,0,!0));let m=0;const I=t?-n:n;let b=0;for(let e=0;e<_.length;e++){const t=_[e];let s=b;for(;s<t&&u(o[s].codePoint);)o[s].glyphMosaicItem=null,++s;let i=t-1;for(;i>s&&u(o[i].codePoint);)o[i].glyphMosaicItem=null,--i;if(s<=i){const e=o[s].x;for(let t=s;t<=i;t++)o[t].x-=e,o[t].y=d;let t=o[i].x;o[i].glyphMosaicItem&&(t+=o[i].glyphMosaicItem.metrics.advance),m=Math.max(t,m),r&&this._applyJustification(o,s,i)}b=t,d+=I}if(o.length>0){const e=_.length-1,s=(r-this._hAnchor)*m;let i=(-this._vAnchor*(e+1)+.5)*n;t&&e&&(i+=e*n);for(const e of o)e.x+=s,e.y+=i}return o.filter(e=>e.glyphMosaicItem)}static getTextBox(e,t){if(!e.length)return null;let s=1/0,i=1/0,n=0,r=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),n=Math.max(n,h),i=Math.min(i,l),r=Math.max(r,c)}return{x:s,y:i,width:n-s,height:r-i}}static getBox(e){if(!e.length)return null;let t=1/0,s=1/0,i=0,n=0;for(const r of e){const{height:e,left:a,top:o,width:l}=r.glyphMosaicItem.metrics,h=r.x,c=r.y-(e-Math.abs(o)),u=h+l+a,f=c+e;t=Math.min(t,h),i=Math.max(i,u),s=Math.min(s,c),n=Math.max(n,f)}return{x:t,y:s,width:i-t,height:n-s}}static addDecoration(e,t){const s=e.length;if(0===s)return;let i=e[0].x+e[0].glyphMosaicItem.metrics.left,n=e[0].y;for(let r=1;r<s;r++){const s=e[r];if(s.y!==n){const a=e[r-1].x+e[r-1].glyphMosaicItem.metrics.left+e[r-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:i,y:n+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new f.A(4,0,4,8),metrics:{width:a-i,height:8,left:0,top:0,advance:0},page:0,code:0}}),n=s.y,i=s.x+s.glyphMosaicItem.metrics.left}}const r=e[s-1].x+e[s-1].glyphMosaicItem.metrics.left+e[s-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:i,y:n+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new f.A(4,0,4,8),metrics:{width:r-i,height:8,left:0,top:0,advance:0},page:0,code:0}})}_breakScore(e,t,s,i){const n=(e-t)*(e-t);return i?e<t?n/2:2*n:n+Math.abs(s)*s}_buildBreak(e,t,s,i,n,r){let a=null,o=this._breakScore(t,s,n,r);for(const e of i){const i=t-e.x,l=this._breakScore(i,s,n,r)+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 i=e[s],n=i.vertical?d:i.glyphMosaicItem?i.glyphMosaicItem.metrics.advance:0,r=(i.x+n)*this._justify;for(let i=t;i<=s;i++)e[i].x-=r}}var p=s(4272);const y=.5;class x{constructor(e,t,s=0,i=-1,n=y){this.x=e,this.y=t,this.angle=s,this.segment=i,this.minzoom=n}}class _{constructor(e,t,s,i,n,r=y,a=o.MG){this.anchor=e,this.labelAngle=t,this.glyphAngle=s,this.page=i,this.alternateVerticalGlyph=n,this.minzoom=r,this.maxzoom=a}}class m{constructor(e,t,s,i,n,r,a,o,l,h,c,u){this.tl=e,this.tr=t,this.bl=s,this.br=i,this.mosaicRect=n,this.labelAngle=r,this.minAngle=a,this.maxAngle=o,this.anchor=l,this.minzoom=h,this.maxzoom=c,this.page=u}}class I{constructor(e){this.shapes=e}}class b{getIconPlacement(e,t,s){const i=new r.bR(e.x,e.y),n=s.rotationAlignment===p.I5.MAP,a=s.keepUpright;let l=s.rotate*o.os;n&&(l+=e.angle);const h=new I([]);return s.allowOverlap&&s.ignorePlacement||(h.iconColliders=[]),this._addIconPlacement(h,i,t,s,l),n&&a&&this._addIconPlacement(h,i,t,s,l+o.Jo),h}_addIconPlacement(e,t,s,i,n){const a=s.rasterizationScale,l=s.width/a,h=s.height/a,c=i.offset;let u=c[0],f=c[1];switch(i.anchor){case p.KI.CENTER:u-=l/2,f-=h/2;break;case p.KI.LEFT:f-=h/2;break;case p.KI.RIGHT:u-=l,f-=h/2;break;case p.KI.TOP:u-=l/2;break;case p.KI.BOTTOM:u-=l/2,f-=h;break;case p.KI.TOP_LEFT:break;case p.KI.BOTTOM_LEFT:f-=h;break;case p.KI.TOP_RIGHT:u-=l;break;case p.KI.BOTTOM_RIGHT:u-=l,f-=h}const d=s.rect,g=2/a,x=u-g,_=f-g,I=x+d.width/a,b=_+d.height/a,M=new r.bR(x,_),w=new r.bR(I,b),k=new r.bR(x,b),T=new r.bR(I,_);if(0!==n){const e=Math.cos(n),t=Math.sin(n);M.rotate(e,t),w.rotate(e,t),k.rotate(e,t),T.rotate(e,t)}const A=new m(M,T,k,w,d,n,0,256,t,y,o.MG,0);if(e.shapes.push(A),!i.allowOverlap||!i.ignorePlacement){const s=i.size,r=i.padding,a={xTile:t.x,yTile:t.y,dxPixels:u*s-r,dyPixels:f*s-r,hard:!i.optional,partIndex:0,width:l*s+2*r,height:h*s+2*r,angle:n,minLod:y,maxLod:o.MG};e.iconColliders.push(a)}}getTextPlacement(e,t,s,i){const n=new r.bR(e.x,e.y),l=i.rotate*o.os,h=i.rotationAlignment===p.I5.MAP,c=i.keepUpright,u=i.padding;let f=y;const x=h?e.angle:0,b=e.segment>=0&&h,M=i.allowOverlap&&i.ignorePlacement?null:[],w=[],k=!b;let T=Number.POSITIVE_INFINITY,A=Number.NEGATIVE_INFINITY,P=T,D=A;const L=(b||h)&&c,V=i.size/d;let B=!1;for(const e of t)if(e.vertical){B=!0;break}let v,R=0,S=0;if(!b&&B){const e=g.getTextBox(t,i.lineHeight*d);switch(i.anchor){case p.KI.LEFT:R=e.height/2,S=-e.width/2;break;case p.KI.RIGHT:R=-e.height/2,S=e.width/2;break;case p.KI.TOP:R=e.height/2,S=e.width/2;break;case p.KI.BOTTOM:R=-e.height/2,S=-e.width/2;break;case p.KI.TOP_LEFT:R=e.height;break;case p.KI.BOTTOM_LEFT:S=-e.width;break;case p.KI.TOP_RIGHT:S=e.width;break;case p.KI.BOTTOM_RIGHT:R=-e.height}}R+=i.offset[0]*d,S+=i.offset[1]*d;for(const d of t){const t=d.glyphMosaicItem;if(!t||t.rect.isEmpty)continue;const g=t.rect,p=t.metrics,I=t.page;if(M&&k){if(void 0!==v&&v!==d.y){let t,s,n,r;B?(t=-D+R,s=T+S,n=D-P,r=A-T):(t=T+R,s=P+S,n=A-T,r=D-P);const a={xTile:e.x,yTile:e.y,dxPixels:t*V-u,dyPixels:s*V-u,hard:!i.optional,partIndex:1,width:n*V+2*u,height:r*V+2*u,angle:l,minLod:y,maxLod:o.MG};M.push(a),T=Number.POSITIVE_INFINITY,A=Number.NEGATIVE_INFINITY,P=T,D=A}v=d.y}const C=[];if(b){const i=.5*t.metrics.width,n=(d.x+p.left-4+i)*V*a.ih;if(f=this._placeGlyph(e,f,n,s,e.segment,1,d.vertical,I,C),c&&(f=this._placeGlyph(e,f,n,s,e.segment,-1,d.vertical,I,C)),f>=2)break}else C.push(new _(n,x,x,I,!1)),h&&c&&C.push(new _(n,x+o.Jo,x+o.Jo,I,!1));const E=d.x+p.left,O=d.y-17-p.top,F=E+p.width,N=O+p.height;let U,z,G,K,q,H,W,j;if(!b&&B)if(d.vertical){const e=(E+F)/2-p.height/2,t=(O+N)/2+p.width/2;U=new r.bR(-t-4+R,e-4+S),z=new r.bR(U.x+g.width,U.y+g.height),G=new r.bR(U.x,z.y),K=new r.bR(z.x,U.y)}else U=new r.bR(4-O+R,E-4+S),z=new r.bR(U.x-g.height,U.y+g.width),G=new r.bR(z.x,U.y),K=new r.bR(U.x,z.y);else U=new r.bR(E-4+R,O-4+S),z=new r.bR(U.x+g.width,U.y+g.height),G=new r.bR(U.x,z.y),K=new r.bR(z.x,U.y);for(const t of C){let s,n,a,o;if(t.alternateVerticalGlyph){if(!q){const e=(O+N)/2+S;q=new r.bR((E+F)/2+R-p.height/2-4,e+p.width/2+4),H=new r.bR(q.x+g.height,q.y-g.width),W=new r.bR(H.x,q.y),j=new r.bR(q.x,H.y)}s=q,n=W,a=j,o=H}else s=U,n=G,a=K,o=z;const h=O,c=N,f=t.glyphAngle+l;if(0!==f){const e=Math.cos(f),t=Math.sin(f);s=s.clone(),n=n?.clone(),a=a?.clone(),o=o?.clone(),s.rotate(e,t),o?.rotate(e,t),n?.rotate(e,t),a?.rotate(e,t)}let y=0,x=256;if(b&&B?d.vertical?t.alternateVerticalGlyph?(y=32,x=96):(y=224,x=32):(y=224,x=96):(y=192,x=64),w.push(new m(s,a,n,o,g,t.labelAngle,y,x,t.anchor,t.minzoom,t.maxzoom,t.page)),M&&(!L||this._legible(t.labelAngle)))if(k)E<T&&(T=E),h<P&&(P=h),F>A&&(A=F),c>D&&(D=c);else if(t.minzoom<2){const s={xTile:e.x,yTile:e.y,dxPixels:(E+R)*V-u,dyPixels:(h+R)*V-u,hard:!i.optional,partIndex:1,width:(F-E)*V+2*u,height:(c-h)*V+2*u,angle:f,minLod:t.minzoom,maxLod:t.maxzoom};M.push(s)}}}if(f>=2)return null;if(M&&k){let t,s,n,r;B?(t=-D+R,s=T+S,n=D-P,r=A-T):(t=T+R,s=P+S,n=A-T,r=D-P);const a={xTile:e.x,yTile:e.y,dxPixels:t*V-u,dyPixels:s*V-u,hard:!i.optional,partIndex:1,width:n*V+2*u,height:r*V+2*u,angle:l,minLod:y,maxLod:o.MG};M.push(a)}const C=new I(w);return M&&M.length>0&&(C.textColliders=M),C}_legible(e){const t=(0,o.z0)(e);return t<65||t>=193}_placeGlyph(e,t,s,i,n,a,l,h,c){let u=a;const f=u<0?(0,o.Wh)(e.angle+o.Jo,o.pJ):e.angle;let d=0;s<0&&(u*=-1,s*=-1,d=o.Jo),u>0&&++n;let g=new r.bR(e.x,e.y),p=i[n],y=o.MG;if(i.length<=n)return y;for(;;){const e=p.x-g.x,r=p.y-g.y,a=Math.sqrt(e*e+r*r),x=Math.max(s/a,t),m=e/a,I=r/a,b=(0,o.Wh)(Math.atan2(I,m)+d,o.pJ);if(c.push(new _(g,f,b,h,!1,x,y)),l&&c.push(new _(g,f,b,h,!0,x,y)),x<=t)return x;g=p.clone();do{if(n+=u,i.length<=n||n<0)return x;p=i[n]}while(g.isEqual(p));let M=p.x-g.x,w=p.y-g.y;const k=Math.sqrt(M*M+w*w);M*=a/k,w*=a/k,g.x-=M,g.y-=w,y=x}}}var M,w,k=s(51624),T=s(15585);(w=M||(M={}))[w.moveTo=1]="moveTo",w[w.lineTo=2]="lineTo",w[w.close=7]="close";class A{constructor(e,t,s=0){this.values={},this._geometry=void 0,this._pbfGeometry=null,this.featureIndex=s;const i=t.keys,n=t.values,r=e.asUnsafe();for(;r.next();)switch(r.tag()){case 1:this.id=r.getUInt64();break;case 2:{const e=r.getMessage().asUnsafe(),t=this.values;for(;!e.empty();){const s=e.getUInt32(),r=e.getUInt32();t[i[s]]=n[r]}e.release();break}case 3:this.type=r.getUInt32();break;case 4:this._pbfGeometry=r.getMessage();break;default:r.skip()}}getGeometry(e){if(void 0!==this._geometry)return this._geometry;if(!this._pbfGeometry)return null;const t=this._pbfGeometry.asUnsafe();let s,i;this._pbfGeometry=null,e?e.reset(this.type):s=[];let n,a=M.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 M.moveTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.moveTo(l,h):s&&(i&&s.push(i),i=[],i.push(new r.bR(l,h)));break;case M.lineTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.lineTo(l,h):i&&i.push(new r.bR(l,h));break;case M.close:e?e.close():i&&!i[0].equals(l,h)&&i.push(i[0].clone());break;default:throw t.release(),new Error("Invalid path operation")}}return e?n=e.result():s&&(i&&s.push(i),n=s),t.release(),this._geometry=n,n}}var P=s(80081);class D extends P.A{constructor(){super(12)}add(e,t,s){const i=this.array;i.push(e),i.push(t),i.push(s)}}P.A;class L{constructor(e){this.extent=a.vA,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(L._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 V extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a,o,l,h,c,u){const f=this.array;let d=P.A.i1616to32(e,t);f.push(d);const g=31;d=P.A.i8888to32(Math.round(g*s),Math.round(g*i),Math.round(g*n),Math.round(g*r)),f.push(d),d=P.A.i8888to32(Math.round(g*a),Math.round(g*o),Math.round(g*l),Math.round(g*h)),f.push(d),d=P.A.i1616to32(c,0),f.push(d),u&&f.push(...u)}}class B extends P.A{constructor(e){super(e)}add(e,t,s){const i=this.array;i.push(P.A.i1616to32(e,t)),s&&i.push(...s)}}class v extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a){const o=this.array,l=this.index;let h=P.A.i1616to32(e,t);return o.push(h),h=P.A.i8888to32(Math.round(15*s),Math.round(15*i),n,r),o.push(h),a&&o.push(...a),l}}class R extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a,l,h,c,u,f){const d=this.array;let g=P.A.i1616to32(e,t);d.push(g),g=P.A.i1616to32(Math.round(8*s),Math.round(8*i)),d.push(g),g=P.A.i8888to32(n/4,r/4,l,h),d.push(g),g=P.A.i8888to32(0,(0,o.z0)(a),10*c,Math.min(10*u,255)),d.push(g),f&&d.push(...f)}}class S extends P.A{constructor(e){super(e)}add(e,t,s,i,n){const r=this.array,a=P.A.i1616to32(2*e+s,2*t+i);r.push(a),n&&r.push(...n)}}class C{constructor(e,t,s){this.layerExtent=a.vA,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 E extends C{constructor(e,t,s,i,r){super(e,t,s),this.type=n.NP.CIRCLE,this._circleVertexBuffer=i,this._circleIndexBuffer=r}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 i=this.layer,n=this.zoom;e&&e.setExtent(this.layerExtent);for(const r of this._features){const a=r.getGeometry(e);if(!a)continue;const o=i.circleMaterial.encodeAttributes(r,n,i);for(const e of a)if(e)for(const i of e){const e=t.index;t.add(i.x,i.y,0,0,o),t.add(i.x,i.y,0,1,o),t.add(i.x,i.y,1,0,o),t.add(i.x,i.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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._circleIndexStart,t[i++]=this._circleIndexCount,t[i++]=this._circleVertexBuffer.array.length;for(let e=0;e<this._circleVertexBuffer.array.length;e++)s[i++]=this._circleVertexBuffer.array[e];t[i++]=this._circleIndexBuffer.array.length;for(let e=0;e<this._circleIndexBuffer.array.length;e++)t[i++]=this._circleIndexBuffer.array[e];return t.buffer}}var O=s(98291),F=s(83349);class N extends C{constructor(e,t,s,i,r,a,o){super(e,t,s),this.type=n.NP.FILL,this._patternMap=new Map,this._fillVertexBuffer=i,this._fillIndexBuffer=r,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 i=this.layer,n=this.zoom,r=i.getPaintProperty("fill-pattern");if(r)if(r.isDataDriven)for(const e of this._features)t(r.getValue(n,e),!0);else t(r.getValue(n),!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:i,outlineMaterial:n,hasDataDrivenFill:r,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),i=t.getPaintValue("fill-opacity",s+1);e<1&&i<1&&(h=!1)}if(h&&!t.hasDataDrivenColor){const e=t.getPaintValue("fill-color",s),i=t.getPaintValue("fill-color",s+1);e[3]<1&&i[3]<1&&(h=!1)}}const c=this._features,u=e?.validateTessellation;if(l){const r=[];for(const l of c){const c=o.getValue(s,l),f=this._spriteInfo[c];if(!f?.rect)continue;const d=i.encodeAttributes(l,s,t,f),g=h&&a?n.encodeAttributes(l,s,t):[],p=l.getGeometry(e);r.push({ddFillAttributes:d,ddOutlineAttributes:g,page:f.page,geometry:p}),r.sort((e,t)=>e.page-t.page);for(const{ddFillAttributes:e,ddOutlineAttributes:s,page:i,geometry:n}of r)this._processFeature(n,h,t.outlineUsesFillColor,e,s,u,i)}}else for(const o of c){const l=r?i.encodeAttributes(o,s,t):null,c=h&&a?n.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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._fillIndexStart,t[i++]=this._fillIndexCount,t[i++]=this._outlineIndexStart,t[i++]=this._outlineIndexCount;const n=this._patternMap,r=n.size;if(t[i++]=r,r>0)for(const[e,[s,r]]of n)t[i++]=e,t[i++]=s,t[i++]=r;t[i++]=this._fillVertexBuffer.array.length;for(let e=0;e<this._fillVertexBuffer.array.length;e++)s[i++]=this._fillVertexBuffer.array[e];t[i++]=this._fillIndexBuffer.array.length;for(let e=0;e<this._fillIndexBuffer.array.length;e++)t[i++]=this._fillIndexBuffer.array[e];t[i++]=this._outlineVertexBuffer.array.length;for(let e=0;e<this._outlineVertexBuffer.array.length;e++)s[i++]=this._outlineVertexBuffer.array[e];t[i++]=this._outlineIndexBuffer.array.length;for(let e=0;e<this._outlineIndexBuffer.array.length;e++)t[i++]=this._outlineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s,i,n,r,a){if(!e)return;const o=e.length,l=!n||0===n.length;if(t&&(!s||l))for(let t=0;t<o;t++)this._processOutline(e[t],n);let h;for(let t=0;t<o;t++){const s=N._area(e[t]);s>32?(void 0!==h&&this._processFill(e,h,i,r,a),h=[t]):s<-32&&void 0!==h&&h.push(t)}void 0!==h&&this._processFill(e,h,i,r,a)}_processOutline(e,t){const s=this._outlineVertexBuffer,i=this._outlineIndexBuffer,n=i.index;let a,o,l;const h=new r.bR(0,0),c=new r.bR(0,0),u=new r.bR(0,0);let f=-1,d=-1,g=-1,p=-1,y=-1,x=!1,_=e.length;if(_<2)return;const m=e[0];let I=e[_-1];for(;_&&I.isEqual(m);)--_,I=e[_-1];if(!(_-0<2)){for(let n=0;n<_;++n){0===n?(a=e[_-1],o=e[0],l=e[1],h.assignSub(o,a),h.normalize(),h.rightPerpendicular()):(a=o,o=l,l=n!==_-1?e[n+1]:e[0],h.assign(c));const r=this._isClipEdge(a,o);-1===p&&(x=r),c.assignSub(l,o),c.normalize(),c.rightPerpendicular();const m=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),m>=0?(g=s.add(o.x,o.y,h.x,h.y,0,1,t),-1===p&&(p=g),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,b*-u.x,b*-u.y,0,-1,t),-1===y&&(y=d),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=d,d=g,g=s.add(o.x,o.y,u.x,u.y,0,1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,c.x,c.y,0,1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g)):(g=s.add(o.x,o.y,b*u.x,b*u.y,0,1,t),-1===p&&(p=g),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,-h.x,-h.y,0,-1,t),-1===y&&(y=d),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=d,d=g,g=s.add(o.x,o.y,-u.x,-u.y,0,-1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=s.add(o.x,o.y,-c.x,-c.y,0,-1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g))}f>=0&&d>=0&&p>=0&&!x&&i.add(f,d,p),f>=0&&p>=0&&y>=0&&!x&&i.add(f,y,p),this._outlineIndexCount+=3*(i.index-n)}}_processFill(e,t,s,i,n){let r;t.length>1&&(r=[]);let a=0;for(const s of t)0!==a&&r.push(a),a+=e[s].length;const o=2*a,l=O.A.acquire();for(const s of t){const t=e[s],i=t.length;for(let e=0;e<i;++e)l.push(t[e].x,t[e].y)}const h=(0,F.e)(l,r,2);if(F.e.deviation(l,r,2,h)>0){const i=t.map(t=>e[t].length),{buffer:r,vertexCount:a}=(0,T.l)(l,i);if(a>0){const e=this._fillVertexBuffer.index;for(let e=0;e<a;e++)this._fillVertexBuffer.add(r[2*e],r[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!==n){const e=this._patternMap,t=e.get(n);t?t[1]+=a:e.set(n,[this._fillIndexStart+this._fillIndexCount,a])}this._fillIndexCount+=a}}else{const e=h.length;if(e>0){const t=this._fillVertexBuffer.index;let i=0;for(;i<o;)this._fillVertexBuffer.add(l[i++],l[i++],s);let r=0;for(;r<e;)this._fillIndexBuffer.add(t+h[r++],t+h[r++],t+h[r++]);if(void 0!==n){const t=this._patternMap,s=t.get(n);s?s[1]+=e:t.set(n,[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 i=0;i<s;i++)t+=(e[i].x-e[i+1].x)*(e[i].y+e[i+1].y);return t+=(e[s].x-e[0].x)*(e[s].y+e[0].y),.5*t}}var U=s(83773);class z extends C{constructor(e,t,s,i,r){super(e,t,s),this.type=n.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=i,this.tessellationProperties._lineIndexBuffer=r,this._lineTessellator=new U.i(G(this.tessellationProperties),K(this.tessellationProperties),e.canUseThinTessellation)}get lineIndexStart(){return this._lineIndexStart}get lineIndexCount(){return this._lineIndexCount}getResources(e,t,s){const i=this.layer,n=this.zoom,r=i.getPaintProperty("line-pattern"),a=i.getPaintProperty("line-dasharray"),o=i.getLayoutProperty("line-cap");if(!r&&!a)return;const l=o?.getValue(n)||0,h=o?.isDataDriven,c=r?.isDataDriven,u=a?.isDataDriven;if(c||u)for(const e of this._features)t(c?r.getValue(n,e):this._getDashArrayKey(e,n,i,a,h,o,l));else if(r)t(r.getValue(n));else if(a){const e=a.getValue(n);t(i.getDashKey(e,l))}}processFeatures(e){this._lineIndexStart=3*this.tessellationProperties._lineIndexBuffer.index,this._lineIndexCount=0;const t=this.layer,s=this.zoom,i=this._features,n=this._tessellationOptions,{hasDataDrivenLine:r,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),g=d||0,p=!!f;u=t.getLayoutProperty("line-join");const y=u?.isDataDriven?u:null,x=y?null:t.getLayoutValue("line-join",s);u=t.getLayoutProperty("line-miter-limit");const _=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 k=u?.isDataDriven?u:null,T=k?null:t.getPaintValue("line-offset",s);if(h||c){const r=[];for(const n of i){const i=h?o.getValue(s,n):this._getDashArrayKey(n,s,t,l,p,f,g),c=this._spriteInfo[i];if(!c?.rect)continue;const u=a.encodeAttributes(n,s,t,c),A=n.getGeometry(e);r.push({ddAttributes:u,page:c.page,cap:f?f.getValue(s,n):d,join:y?y.getValue(s,n):x,miterLimit:_?_.getValue(s,n):m,roundLimit:I?I.getValue(s,n):b,halfWidth:.5*(M?M.getValue(s,n):w),offset:k?k.getValue(s,n):T,geometry:A})}r.sort((e,t)=>e.page-t.page),n.textured=!0;for(const{ddAttributes:e,page:t,cap:s,join:i,miterLimit:a,roundLimit:o,halfWidth:l,offset:h,geometry:c}of r)n.capType=s,n.joinType=i,n.miterLimit=a,n.roundLimit=o,n.halfWidth=l,n.offset=h,this._processFeature(c,e,t)}else{if(o){const e=o.getValue(s),t=this._spriteInfo[e];if(!t?.rect)return}n.textured=!(!o&&!l),n.capType=d,n.joinType=x,n.miterLimit=m,n.roundLimit=b,n.halfWidth=.5*w,n.offset=T;for(const o of i){const i=r?a.encodeAttributes(o,s,t):null;f&&(n.capType=f.getValue(s,o)),y&&(n.joinType=y.getValue(s,o)),_&&(n.miterLimit=_.getValue(s,o)),I&&(n.roundLimit=I.getValue(s,o)),M&&(n.halfWidth=.5*M.getValue(s,o)),k&&(n.offset=k.getValue(s,o));const l=o.getGeometry(e);this._processFeature(l,i)}}}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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._lineIndexStart,t[i++]=this._lineIndexCount;const n=this._patternMap,r=n.size;if(t[i++]=r,r>0)for(const[e,[s,r]]of n)t[i++]=e,t[i++]=s,t[i++]=r;t[i++]=this.tessellationProperties._lineVertexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineVertexBuffer.array.length;e++)s[i++]=this.tessellationProperties._lineVertexBuffer.array[e];t[i++]=this.tessellationProperties._lineIndexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineIndexBuffer.array.length;e++)t[i++]=this.tessellationProperties._lineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s){if(!e)return;const i=e.length;for(let n=0;n<i;n++)this._processGeometry(e[n],t,s)}_processGeometry(e,t,s){if(e.length<2)return;let i,n,r=e[0],a=1;for(;a<e.length;)i=e[a].x-r.x,n=e[a].y-r.y,i*i+n*n<1e-6?e.splice(a,1):(r=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,i,n,r,a){const o=n?r.getValue(t,e):a,l=i.getValue(t,e);return s.getDashKey(l,o)}}const G=e=>(t,s,i,n,r,a,o,l,h,c,u)=>(e._lineVertexBuffer.add(t,s,o,l,i,n,r,a,h,c,u,e._ddValues),e._lineVertexBuffer.index-1),K=e=>(t,s,i)=>{e._lineIndexBuffer.add(t,s,i)};var q,H=s(32488),W=s(97768),j=s(799),Y=s(3057);function J(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 Z extends C{constructor(e,t,s,i,r,a,o,l,h){super(t,s,h.getSpriteItems()),this.type=n.NP.SYMBOL,this._markerMap=new Map,this._glyphMap=new Map,this._glyphBufferDataStorage=new Map,this._isIconSDF=!1,this._sourceTileKey=e,this._iconVertexBuffer=i,this._iconIndexBuffer=r,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}static{this._bidiEngine=new H.A}getResources(e,t,s){const i=this.layer,n=this.zoom;e&&e.setExtent(this.layerExtent);const r=i.getLayoutProperty("icon-image"),a=i.getLayoutProperty("text-field");let o=i.getLayoutProperty("text-transform"),l=i.getLayoutProperty("text-font");const h=[];let c,u,f,d;r&&!r.isDataDriven&&(c=r.getValue(n)),a&&!a.isDataDriven&&(u=a.getValue(n)),o&&o.isDataDriven||(f=i.getLayoutValue("text-transform",n),o=null),l&&l.isDataDriven||(d=i.getLayoutValue("text-font",n),l=null);for(const g of this._features){const y=g.getGeometry(e);if(!y||0===y.length)continue;let x,_;r&&(x=r.isDataDriven?r.getValue(n,g):this._replaceKeys(c,g.values),x&&t(x));let m=!1;if(a&&(_=a.isDataDriven?a.getValue(n,g):this._replaceKeys(u,g.values),_)){switch(_=_.replaceAll("\\n","\n"),o&&(f=o.getValue(n,g)),f){case p.Ms.LOWERCASE:_=_.toLowerCase();break;case p.Ms.UPPERCASE:_=_.toUpperCase()}if(Z._bidiEngine.hasBidiChar(_)){let e;e="rtl"===Z._bidiEngine.checkContextual(_)?"IDNNN":"ICNNN",_=Z._bidiEngine.bidiTransform(_,e,"VLYSN"),m=!0}if(_.length>0){l&&(d=l.getValue(n,g));for(const e of d){let t=s[e];t||(t=s[e]=new Set);for(const e of _){const s=e.codePointAt(0);null!=s&&t.add(s)}}}}if(!x&&!_)continue;const I=i.getLayoutValue("symbol-sort-key",n,g),b={feature:g,sprite:x,label:_,rtl:m,geometry:y,hash:(_?(0,j.Wm)(_):0)^(x?(0,j.Wm)(x):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,i=t.getLayoutValue("symbol-placement",s),n=i!==p.kt.POINT,l=t.getLayoutValue("symbol-spacing",s)*a.ih,h=t.getLayoutProperty("icon-image"),c=t.getLayoutProperty("text-field"),u=h?new Y.aR(t,s,n):null,f=c?new Y.uU(t,s,n):null,y=this._workerTileHandler;let _;h&&(_=y.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 I=1;f?.size&&(I=f.size/d);const b=f?f.maxAngle*o.os:0,M=f?f.size*a.ih:0;for(const e of this._symbolFeatures){let t,o;u&&_&&e.sprite&&(t=_[e.sprite],t&&t.sdf&&(this._isIconSDF=!0)),t&&u.update(s,e.feature);let h=0;const c=e.label;if(c){(0,W.Lw)(f),f.update(s,e.feature);const t=n&&f.rotationAlignment===p.I5.MAP?f.keepUpright:f.writingMode&&f.writingMode.includes(p.v9.VERTICAL);let i=.5;switch(f.anchor){case p.KI.TOP_LEFT:case p.KI.LEFT:case p.KI.BOTTOM_LEFT:i=0;break;case p.KI.TOP_RIGHT:case p.KI.RIGHT:case p.KI.BOTTOM_RIGHT:i=1}let r=.5;switch(f.anchor){case p.KI.TOP_LEFT:case p.KI.TOP:case p.KI.TOP_RIGHT:r=0;break;case p.KI.BOTTOM_LEFT:case p.KI.BOTTOM:case p.KI.BOTTOM_RIGHT:r=1}let l=.5;switch(f.justify){case p.O6.AUTO:l=i;break;case p.O6.LEFT:l=0;break;case p.O6.RIGHT:l=1}const u=f.letterSpacing*d,x=n?0:f.maxWidth*d,_=f.lineHeight*d,m=e.textFont.map(e=>y.getGlyphItems(e));if(o=new g(m,x,_,u,i,r,l).getShaping(c,e.rtl,t),o&&o.length>0){let e=1e30,t=-1e30;for(const s of o)e=Math.min(e,s.x),t=Math.max(t,s.x);h=(t-e+48)*I*a.ih}}for(let s of e.geometry){const c=[];if(i===p.kt.LINE){if(o?.length&&f?.size){const e=f.size*a.ih*(2+Math.min(2,4*Math.abs(f.offset[1])));s=Z._smoothVertices(s,e)}Z._pushAnchors(c,s,l,h)}else i===p.kt.LINE_CENTER?Z._pushCenterAnchor(c,s):e.feature.type===r.dC.Polygon?Z._pushCentroid(c,s):c.push(new x(s[0].x,s[0].y));for(const i of c){if(i.x<0||i.x>a.vA||i.y<0||i.y>a.vA)continue;if(n&&h>0&&f?.rotationAlignment===p.I5.MAP&&!Z._honorsTextMaxAngle(s,i,h,b,M))continue;const r={shaping:o,line:s,iconMosaicItem:t,anchor:i,symbolFeature:e,textColliders:[],iconColliders:[],textVertexRanges:[],iconVertexRanges:[]};m.push(r),this._processFeature(r,u,f)}}}m.sort(J),this._addPlacedGlyphs(),this._symbolInstances=m}serialize(){let e=14;e+=this.layerUIDs.length,e+=3*this.markerPageMap.size,e+=3*this.glyphsPageMap.size,e+=Z._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),i=new Float32Array(t.buffer),[n,r,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(n),t[o++]=parseFloat(r),t[o++]=parseFloat(a),t[o++]=this.markerPageMap.size;for(const[e,[s,i]]of this.markerPageMap)t[o++]=e,t[o++]=s,t[o++]=i;t[o++]=this.glyphsPageMap.size;for(const[e,[s,i]]of this.glyphsPageMap)t[o++]=e,t[o++]=s,t[o++]=i;t[o++]=this._iconVertexBuffer.index/4,t[o++]=this._textVertexBuffer.index/4,o=Z.serializeSymbols(t,s,i,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,i,n){n=n||[],t[i++]=n.length;for(const e of n){t[i++]=e.anchor.x,t[i++]=e.anchor.y,t[i++]=e.symbolFeature.hash,t[i++]=e.symbolFeature.priority,t[i++]=e.symbolFeature.feature.featureIndex,t[i++]=e.textColliders.length+e.iconColliders.length;for(const n of e.textColliders)t[i++]=n.xTile,t[i++]=n.yTile,t[i++]=n.dxPixels,t[i++]=n.dyPixels,t[i++]=n.hard?1:0,t[i++]=n.partIndex,s[i++]=n.minLod,s[i++]=n.maxLod,t[i++]=n.width,t[i++]=n.height;for(const n of e.iconColliders)t[i++]=n.xTile,t[i++]=n.yTile,t[i++]=n.dxPixels,t[i++]=n.dyPixels,t[i++]=n.hard?1:0,t[i++]=n.partIndex,s[i++]=n.minLod,s[i++]=n.maxLod,t[i++]=n.width,t[i++]=n.height;t[i++]=e.textVertexRanges.length;for(const[s,n]of e.textVertexRanges)t[i++]=s,t[i++]=n;t[i++]=e.iconVertexRanges.length;for(const[s,n]of e.iconVertexRanges)t[i++]=s,t[i++]=n}return i}_replaceKeys(e,t){return e.replaceAll(/{([^{}]+)}/g,(e,s)=>s in t?t[s]:"")}_processFeature(e,t,s){const{line:i,iconMosaicItem:n,shaping:r,anchor:a}=e,l=this.zoom,h=this.layer,c=!!n;let u=!0;c&&(u=t?.optional||!n);const f=r&&r.length>0,d=!f||s?.optional;let g,y;if(c&&(g=this._placementEngine.getIconPlacement(a,n,t)),(g||u)&&(f&&(y=this._placementEngine.getTextPlacement(a,r,i,s)),y||d)){if(g&&y||(d||u?d||y?u||g||(y=null):g=null:(g=null,y=null)),y){const t=h.hasDataDrivenText?h.textMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._storePlacedGlyphs(e,y.shapes,l,s.rotationAlignment,t),y.textColliders){e.textColliders=y.textColliders;for(const e of y.textColliders){e.minLod=Math.max(l+(0,o.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,o.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),i=Math.sin(t),n=e.dxPixels*s-e.dyPixels*i,r=e.dxPixels*i+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*i,o=(e.dxPixels+e.width)*i+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*i,h=e.dxPixels*i+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*i,u=(e.dxPixels+e.width)*i+(e.dyPixels+e.height)*s,f=Math.min(n,a,l,c),d=Math.max(n,a,l,c),g=Math.min(r,o,h,u),p=Math.max(r,o,h,u);e.dxPixels=f,e.dyPixels=g,e.width=d-f,e.height=p-g}}}}if(g){const s=h.hasDataDrivenIcon?h.iconMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._addPlacedIcons(e,g.shapes,l,n.page,t.rotationAlignment===p.I5.VIEWPORT,s),g.iconColliders){e.iconColliders=g.iconColliders;for(const e of g.iconColliders){e.minLod=Math.max(l+(0,o.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,o.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),i=Math.sin(t),n=e.dxPixels*s-e.dyPixels*i,r=e.dxPixels*i+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*i,o=(e.dxPixels+e.width)*i+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*i,h=e.dxPixels*i+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*i,u=(e.dxPixels+e.width)*i+(e.dyPixels+e.height)*s,f=Math.min(n,a,l,c),d=Math.max(n,a,l,c),g=Math.min(r,o,h,u),p=Math.max(r,o,h,u);e.dxPixels=f,e.dyPixels=g,e.width=d-f,e.height=p-g}}}}}}_addPlacedIcons(e,t,s,i,n,r){const a=Math.max(s-1,0),l=this._iconVertexBuffer,h=this._iconIndexBuffer,c=this._markerMap;for(const u of t){const t=n?0:Math.max(s+(0,o.p6)(u.minzoom),a),f=n?25:Math.min(s+(0,o.p6)(u.maxzoom),25);if(f<=t)continue;const d=u.tl,g=u.tr,p=u.bl,y=u.br,x=u.mosaicRect,_=u.labelAngle,m=u.minAngle,I=u.maxAngle,b=u.anchor,M=l.index,w=x.x,k=x.y,T=w+x.width,A=k+x.height,P=l.index;l.add(b.x,b.y,d.x,d.y,w,k,_,m,I,t,f,r),l.add(b.x,b.y,g.x,g.y,T,k,_,m,I,t,f,r),l.add(b.x,b.y,p.x,p.y,w,A,_,m,I,t,f,r),l.add(b.x,b.y,y.x,y.y,T,A,_,m,I,t,f,r),e.iconVertexRanges.length>0&&e.iconVertexRanges[0][0]+e.iconVertexRanges[0][1]===P?e.iconVertexRanges[0][1]+=4:e.iconVertexRanges.push([P,4]),h.add(M,M+1,M+2),h.add(M+1,M+2,M+3),c.has(i)?c.get(i)[1]+=6:c.set(i,[this._iconIndexStart+this._iconIndexCount,6]),this._iconIndexCount+=6}}_addPlacedGlyphs(){const e=this._textVertexBuffer,t=this._textIndexBuffer,s=this._glyphMap;for(const[i,n]of this._glyphBufferDataStorage)for(const r of n){const n=e.index,a=r.symbolInstance,o=r.ddAttributes,l=e.index;e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.tl[0],r.tl[1],r.xmin,r.ymin,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.tr[0],r.tr[1],r.xmax,r.ymin,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.bl[0],r.bl[1],r.xmin,r.ymax,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.br[0],r.br[1],r.xmax,r.ymax,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.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(n,n+1,n+2),t.add(n+1,n+2,n+3),s.has(i)?s.get(i)[1]+=6:s.set(i,[this._textIndexStart+this._textIndexCount,6]),this._textIndexCount+=6}this._glyphBufferDataStorage.clear()}_storePlacedGlyphs(e,t,s,i,n){const r=Math.max(s-1,0),a=i===p.I5.VIEWPORT;let l,h,c,u,f,d,g,y,x,_,m;for(const i of t)l=a?0:Math.max(s+(0,o.p6)(i.minzoom),r),h=a?25:Math.min(s+(0,o.p6)(i.maxzoom),25),h<=l||(c=i.tl,u=i.tr,f=i.bl,d=i.br,g=i.labelAngle,y=i.minAngle,x=i.maxAngle,_=i.anchor,m=i.mosaicRect,this._glyphBufferDataStorage.has(i.page)||this._glyphBufferDataStorage.set(i.page,[]),this._glyphBufferDataStorage.get(i.page).push({glyphAnchor:[_.x,_.y],tl:[c.x,c.y],tr:[u.x,u.y],bl:[f.x,f.y],br:[d.x,d.y],xmin:m.x,ymin:m.y,xmax:m.x+m.width,ymax:m.y+m.height,labelAngle:g,minAngle:y,maxAngle:x,minLod:l,maxLod:h,placementLod:r,symbolInstance:e,ddAttributes:n}))}static _pushAnchors(e,t,s,i){s+=i;let n=0;const a=t.length-1;for(let e=0;e<a;e++)n+=r.bR.distance(t[e],t[e+1]);let l=i||s;if(l*=.5,n<=l)return;const h=l/n;let c=0,u=-(s=n/Math.max(Math.round(n/s),1))/2;const f=t.length-1;for(let i=0;i<f;i++){const n=t[i],r=t[i+1],a=r.x-n.x,l=r.y-n.y,f=Math.sqrt(a*a+l*l);let d;for(;u+s<c+f;){u+=s;const t=(u-c)/f,g=(0,o.GW)(n.x,r.x,t),p=(0,o.GW)(n.y,r.y,t);void 0===d&&(d=Math.atan2(l,a)),e.push(new x(g,p,d,i,h))}c+=f}}static _pushCenterAnchor(e,t){let s=0;const i=t.length-1;for(let e=0;e<i;e++)s+=r.bR.distance(t[e],t[e+1]);const n=s/2;let a=0;const l=t.length-1;for(let s=0;s<l;s++){const i=t[s],r=t[s+1],l=r.x-i.x,h=r.y-i.y,c=Math.sqrt(l*l+h*h);if(n<a+c){const t=(n-a)/c,u=(0,o.GW)(i.x,r.x,t),f=(0,o.GW)(i.y,r.y,t),d=Math.atan2(h,l);return void e.push(new x(u,f,d,s,0))}a+=c}}static _deviation(e,t,s){const i=(t.x-e.x)*(s.x-t.x)+(t.y-e.y)*(s.y-t.y),n=(t.x-e.x)*(s.y-t.y)-(t.y-e.y)*(s.x-t.x);return Math.atan2(n,i)}static _honorsTextMaxAngle(e,t,s,i,n){let a=0;const o=s/2;let l=new r.bR(t.x,t.y),h=t.segment+1;for(;a>-o;){if(--h,h<0)return!1;a-=r.bR.distance(e[h],l),l=e[h]}a+=r.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 g=this._deviation(t,s,l);for(c.push({deviation:g,distToAnchor:a}),u+=g;a-c[0].distToAnchor>n;)u-=c.shift().deviation;if(Math.abs(u)>i)return!1;a+=r.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 i=[];let n=0,a=0;i.push(0);for(let t=1;t<s;t++){const s=r.bR.distance(e[t],e[t-1]);s>0&&(n+=s,i.push(n),a++,a!==t&&(e[a]=e[t]))}if(s=a+1,s<3)return e;t=Math.min(t,.2*n);const o=e[0].x,l=e[0].y,h=e[s-1].x,c=e[s-1].y,u=r.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,i[0]-=t,i[s-1]+=t;const f=[];f.push(new r.bR(o,l));const d=1e-6,g=.5*t;for(let n=1;n<s-1;n++){let a=0,o=0,l=0;for(let s=n-1;s>=0;s--){const r=g+i[s+1]-i[n];if(r<0)break;const h=i[s+1]-i[s],c=i[n]-i[s]<g?1:r/h;if(c<d)break;const u=c*c,f=c*r-.5*u*h,p=c*h/t,y=e[s+1],x=e[s].x-y.x,_=e[s].y-y.y;a+=p/f*(y.x*c*r+.5*u*(r*x-h*y.x)-u*c*h*x/3),o+=p/f*(y.y*c*r+.5*u*(r*_-h*y.y)-u*c*h*_/3),l+=p}for(let r=n+1;r<s;r++){const s=g-i[r-1]+i[n];if(s<0)break;const h=i[r]-i[r-1],c=i[r]-i[n]<g?1:s/h;if(c<d)break;const u=c*c,f=c*s-.5*u*h,p=c*h/t,y=e[r-1],x=e[r].x-y.x,_=e[r].y-y.y;a+=p/f*(y.x*c*s+.5*u*(s*x-h*y.x)-u*c*h*x/3),o+=p/f*(y.y*c*s+.5*u*(s*_-h*y.y)-u*c*h*_/3),l+=p}f.push(new r.bR(a/l,o/l))}return f.push(new r.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=a.vA,i=a.vA,n=t.length-1;let r=0,o=0,l=0,h=t[0].x,c=t[0].y;h>s&&(h=s),h<0&&(h=0),c>i&&(c=i),c<0&&(c=0);for(let e=1;e<n;e++){let n=t[e].x,a=t[e].y,u=t[e+1].x,f=t[e+1].y;n>s&&(n=s),n<0&&(n=0),a>i&&(a=i),a<0&&(a=0),u>s&&(u=s),u<0&&(u=0),f>i&&(f=i),f<0&&(f=0);const d=(n-h)*(f-c)-(u-h)*(a-c);r+=d*(h+n+u),o+=d*(c+a+f),l+=d}r/=3*l,o/=3*l,isNaN(r)||isNaN(o)||e.push(new x(r,o))}}!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"}(q||(q={}));class ${constructor(e,t,s,i,n,a){if(this._pbfTiles={},this._tileClippers={},this._client=s,this._tile=t,this._sourceDataMaxLOD=i,a){this._styleLayerUIDs=new Set;for(const e of a)this._styleLayerUIDs.add(e)}this._styleRepository=n,this._layers=this._styleRepository?.layers??[];const[l,h,c]=t.tileKey.split("/").map(parseFloat);this._level=l;const u=(0,o.IU)(this._level);for(const t of Object.keys(e)){const s=e[t];if(this._pbfTiles[t]=new k.A(new Uint8Array(s.protobuff),new DataView(s.protobuff)),s.refKey){const[e]=s.refKey.split("/").map(parseFloat),i=l-e;if(i>0){const e=(1<<i)-1,s=h&e,n=c&e;this._tileClippers[t]=new r.O3(i,s,n,8,u)}}this._tileClippers[t]||(this._tileClippers[t]=new r.Ox)}}_canParseStyleLayer(e){return!this._styleLayerUIDs||this._styleLayerUIDs.has(e)}async parse(e){const t=(0,T.F)(),s=this._initialize(e),{returnedBuckets:i}=s;this._processLayers(s),this._linkReferences(s),this._filterFeatures(s);const n=[],r=new Set,a=(e,t)=>{r.has(e)||(n.push({name:e,repeat:t}),r.add(e))},o={};for(const e of i)e.getResources(e.tileClipper,a,o);if(this._tile.status===q.INVALID)return[];const l=this._fetchResources(n,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:i,sourceNameToTileClipper:n,sourceNameToUniqueSourceLayerBuckets:r,sourceNameToUniqueSourceLayers:a,returnedBuckets:o,layerIdToBucket:l,referencerUIDToReferencedId:h}=e,c=this._sourceDataMaxLOD;for(let e=i.length-1;e>=0;e--){const u=i[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===p.Dc.BACKGROUND||!this._canParseStyleLayer(u.uid)||!t[u.source]||!n[u.source])continue;const f=t[u.source],d=n[u.source],g=u.sourceLayer,y=f[g];if(y){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=y.extent,e.tileClipper=d;let t=r[u.source];t||(t=r[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:n,sourceNameToUniqueSourceLayers:r}=e,a=10*this._level,o=10*(this._level+1),l=[],h=[];for(const e of Object.keys(r))r[e].forEach(t=>{l.push(t),h.push(e)});for(let e=0;e<l.length;e++){const r=h[e],c=l[e];if(!s[r]||!n[r])continue;const u=s[r][c],f=n[r][c];if(!f||0===f.length)continue;if((0,i.G4)(t))return;let d=0;const g=u.getData();for(;g.nextTag(2);){const e=g.getMessage(),t=new A(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 i=[],n=this._tile.getWorkerTileHandler();let r,a;e.length>0&&(r=n.fetchSprites(e,this._client,s),i.push(r));for(const e in t){const r=t[e];r.size>0&&(a=n.fetchGlyphs(this._tile.tileKey,e,r,this._client,s),i.push(a))}return i}_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 i=e[s],n={};for(;i.next();)switch(i.tag()){case 3:{const e=i.getMessage(),t=new L(e);e.release(),n[t.name]=t;break}default:i.skip()}t[s]=n}return t}_createBucket(e){switch(e.type){case p.Dc.BACKGROUND:return null;case p.Dc.FILL:return this._createFillBucket(e);case p.Dc.LINE:return this._createLineBucket(e);case p.Dc.CIRCLE:return this._createCircleBucket(e);case p.Dc.SYMBOL:return this._createSymbolBucket(e)}}_createFillBucket(e){return new N(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 z(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new V(e.lineMaterial.getStride()),new D)}_createCircleBucket(e){return new E(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new S(e.circleMaterial.getStride()),new D)}_createSymbolBucket(e){const t=this._tile;return new Z(t.tileKey,e,this._level,new R(e.iconMaterial.getStride()),new D,new R(e.textMaterial.getStride()),new D,t.placementEngine,t.getWorkerTileHandler())}}class Q{constructor(e,t,s,i){this.status=q.INITIALIZED,this.placementEngine=new b,this.tileKey=e,this.refKeys=t,this._workerTileHandler=s,this._styleRepository=i}release(){this.tileKey="",this.refKeys=null,this.status=q.INITIALIZED,this._workerTileHandler=null}async parse(e,t){const s=t?.signal;if(null!=s){const e=()=>{s.removeEventListener("abort",e),this.status=q.INVALID};s.addEventListener("abort",e)}let n;const r={bucketsWithData:[],emptyBuckets:null};try{n=await this._parse(e,t)}catch(e){if((0,i.zf)(e))throw e;return{result:r,transferList:[]}}this.status=q.READY;const a=r.bucketsWithData,o=[];for(const e of n)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)),r.emptyBuckets=h,{result:r,transferList:l}}setObsolete(){this.status=q.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=q.MODIFIED,new $(s,this,t.client,e.sourceDataMaxLOD,this._styleRepository,e.styleLayerUIDs).parse(t))}}var X=s(45013);class ee{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,n={};for(const t of Object.keys(e.sourceName2DataAndRefKey)){const s=e.sourceName2DataAndRefKey[t];n[t]=s.refKey}const r=new Q(s,n,this,this._styleRepository);try{return await r.parse({...e,sourceDataMaxLOD:this._sourceDataMaxLOD},t)}catch(e){if(r.setObsolete(),r.release(),!(0,i.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,i=s.data;switch(e){case n.$q.PAINTER_CHANGED:t.setPaintProperties(i.layer,i.paint);break;case n.$q.LAYOUT_CHANGED:t.setLayoutProperties(i.layer,i.layout);break;case n.$q.LAYER_REMOVED:t.deleteStyleLayer(i.layer);break;case n.$q.LAYER_CHANGED:t.setStyleLayer(i.layer,i.index);break;case n.$q.SPRITES_CHANGED:this._spriteInfo={}}}}setStyle(e){const{style:t,sourceDataMaxLOD:s}=e;this._styleRepository=new X.A(t),this._sourceDataMaxLOD=s,this._spriteInfo={},this._glyphInfo={}}fetchSprites(e,t,s){const i=[],n=this._spriteInfo;for(const t of e)void 0===n[t.name]&&i.push(t);return 0===i.length?Promise.resolve():t.invoke("getSprites",i,{signal:s?.signal}).then(e=>{for(const t in e){const s=e[t];n[t]=s}})}getSpriteItems(){return this._spriteInfo}fetchGlyphs(e,t,s,i,n){const r=[];let a=this._glyphInfo[t];return a?s.forEach(e=>{a[e]||r.push(e)}):(a=this._glyphInfo[t]=[],s.forEach(e=>r.push(e))),0===r.length?Promise.resolve():i.invoke("getGlyphs",{tileID:e,font:t,codePoints:r},n).then(e=>{for(let t=0;t<e.length;t++)e[t]&&(a[t]=e[t])})}getGlyphItems(e){return this._glyphInfo[e]}}},34304:(e,t,s)=>{s.d(t,{DF:()=>l,FD:()=>n,Ov:()=>r,ct:()=>h});let i=1e-6;function n(){return i}const r=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:r,equals:function(e,t){return Math.abs(e-t)<=i*Math.max(1,Math.abs(e),Math.abs(t))},getEpsilon:n,setEpsilon:function(e){i=e},toDegree:h,toRadian:l},Symbol.toStringTag,{value:"Module"}))},40876:(e,t,s)=>{s.d(t,{Eq:()=>d,G1:()=>p,TS:()=>r,Tf:()=>_,V6:()=>n,Vm:()=>g,ay:()=>l,c1:()=>y,c4:()=>a,j5:()=>h,lT:()=>u,oW:()=>c});const i={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 n(e){return!!i[e]||!!i[e.toLowerCase()]}function r(e){return i[e]??i[e.toLowerCase()]}function a(e){return[...r(e)]}function o(e,t,s){s<0&&++s,s>1&&--s;const i=6*s;return i<1?e+(t-e)*i:2*s<1?t:3*s<2?e+(t-e)*(2/3-s)*6:e}function l(e,t,s,i=1){const n=(e%360+360)%360/360,r=s<=.5?s*(t+1):s+t-s*t,a=2*s-r;return[Math.round(255*o(a,r,n+1/3)),Math.round(255*o(a,r,n)),Math.round(255*o(a,r,n-1/3)),i]}function h(e){const t=e.length>5,s=t?8:4,i=(1<<s)-1,n=t?1:17,r=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 r&&(l=a&i,a>>=s,o[3]=n*l/255),l=a&i,a>>=s,o[2]=n*l,l=a&i,a>>=s,o[1]=n*l,l=a&i,a>>=s,o[0]=n*l,o}function c(e){if("#"!==e[0]||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{const t=parseInt(e.slice(1,2),16),s=parseInt(e.slice(2,3),16),i=parseInt(e.slice(3,4),16),n=5===e.length?15:parseInt(e.slice(4),16);return[t+16*t,s+16*s,i+16*i,(n+16*n)/255]}case 7:case 9:return[parseInt(e.slice(1,3),16),parseInt(e.slice(3,5),16),parseInt(e.slice(5,7),16),(7===e.length?255:parseInt(e.slice(7),16))/255];default:return null}}function u(e){const t=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(t){const e=t[2].split(/\s*,\s*/),s=t[1];if("rgb"===s&&3===e.length||"rgba"===s&&4===e.length){const t=e[0];if("%"===t.charAt(t.length-1)){const t=e.map(e=>2.56*parseFloat(e));return 4===e.length&&(t[3]=parseFloat(e[3])),f(t)}return f(e.map(e=>parseFloat(e)))}if("hsl"===s&&3===e.length||"hsla"===s&&4===e.length)return l(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3]))}return null}function f(e){return e[0]=y(e[0]),e[1]=y(e[1]),e[2]=y(e[2]),e[3]=4===e.length?p(e[3]):1,e}function d(e){let t=n(e)?r(e):null;return t??=u(e),t??=c(e),t}function g(e){const t=d(e);return null!=t?[t[0]/255,t[1]/255,t[2]/255,t[3]]:null}function p(e){return x(e,0,1)}function y(e){return Math.round(x(e,0,255))}function x(e,t,s){return e=Number(e),isNaN(e)?s:e<t?t:e>s?s:e}const _=2.2},51624:(e,t,s)=>{s.d(t,{A:()=>u});var i,n,r=s(44208),a=s(69397),o=s(93687);(n=i||(i={}))[n.varint=0]="varint",n[n.fixed64=1]="fixed64",n[n.delimited=2]="delimited",n[n.fixed32=5]="fixed32",n[n.unknown=99]="unknown";const l=4294967296,h=new TextDecoder("utf-8"),c=(0,r.A)("safari")||(0,r.A)("ios")?6:(0,r.A)("ff")?12:32;class u{constructor(e,t,s=0,n=(e?e.byteLength:0)){this._tag=0,this._dataType=i.unknown,this._init(e,t,s,n)}_init(e,t,s,i){this._data=e,this._dataView=t,this._pos=s,this._end=i}get usedMemory(){return 64+(0,a.Qf)(this._data)}asUnsafe(){return this}clone(){return new u(this._data,this._dataView,this._pos,this._end)}pos(){return this._pos}move(e){this._pos=e}nextTag(e){for(;;){if(this._pos===this._end)return!1;const t=this._decodeVarint();if(this._tag=t>>3,this._dataType=7&t,!e||e===this._tag)break;this.skip()}return!0}next(){if(this._pos===this._end)return!1;const e=this._decodeVarint();return this._tag=e>>3,this._dataType=7&e,!0}empty(){return this._pos>=this._end}tag(){return this._tag}getInt32(){return this._decodeVarint()}getInt64(){return this._decodeVarint()}getUInt32(){let e=4294967295;if(e=(127&this._data[this._pos])>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<7)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<14)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<21)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(15&this._data[this._pos])<<28)>>>0,this._data[this._pos++]<128)return e;throw new Error("Varint overflow")}getUInt64(){return this._decodeVarint()}getSInt32(){const e=this.getUInt32();return e>>>1^-(1&e)}getSInt64(){return this._decodeSVarint()}getBool(){const e=0!==this._data[this._pos];return this._skip(1),e}getEnum(){return this._decodeVarint()}getFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getUint32(t+4,!0)*l;return this._skip(8),s}getSFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getInt32(t+4,!0)*l;return this._skip(8),s}getDouble(){const e=this._dataView.getFloat64(this._pos,!0);return this._skip(8),e}getFixed32(){const e=this._dataView.getUint32(this._pos,!0);return this._skip(4),e}getSFixed32(){const e=this._dataView.getInt32(this._pos,!0);return this._skip(4),e}getFloat(){const e=this._dataView.getFloat32(this._pos,!0);return this._skip(4),e}getString(){const e=this._getLength(),t=this._pos,s=this._toString(this._data,t,t+e);return this._skip(e),s}getBytes(){const e=this._getLength(),t=this._pos,s=this._toBytes(this._data,t,t+e);return this._skip(e),s}getLength(){return this._getLengthUnsafe()}processMessageWithArgs(e,t,s,i){const n=this.getMessage(),r=e(n,t,s,i);return n.release(),r}processMessage(e){const t=this.getMessage(),s=e(t);return t.release(),s}getMessage(){const e=this._getLength(),t=u.pool.acquire();return t._init(this._data,this._dataView,this._pos,this._pos+e),this._skip(e),t}release(){u.pool.release(this)}dataType(){return this._dataType}skip(){switch(this._dataType){case i.varint:this._decodeVarint();break;case i.fixed64:this._skip(8);break;case i.delimited:this._skip(this._getLength());break;case i.fixed32:this._skip(4);break;default:throw new Error("Invalid data type!")}}skipLen(e){this._skip(e)}_skip(e){if(this._pos+e>this._end)throw new Error("Attempt to skip past the end of buffer!");this._pos+=e}_decodeVarint(){const e=this._data;let t=this._pos,s=0,i=0;if(this._end-t>=10)do{if(i=e[t++],s|=127&i,!(128&i))break;if(i=e[t++],s|=(127&i)<<7,!(128&i))break;if(i=e[t++],s|=(127&i)<<14,!(128&i))break;if(i=e[t++],s|=(127&i)<<21,!(128&i))break;if(i=e[t++],s+=268435456*(127&i),!(128&i))break;if(i=e[t++],s+=34359738368*(127&i),!(128&i))break;if(i=e[t++],s+=4398046511104*(127&i),!(128&i))break;if(i=e[t++],s+=562949953421312*(127&i),!(128&i))break;if(i=e[t++],s+=72057594037927940*(127&i),!(128&i))break;if(i=e[t++],s+=0x8000000000000000*(127&i),!(128&i))break;throw new Error("Varint too long!")}while(0);else{let n=1;for(;t!==this._end&&(i=e[t],128&i);)++t,s+=(127&i)*n,n*=128;if(t===this._end)throw new Error("Varint overrun!");++t,s+=i*n}return this._pos=t,s}_decodeSVarint(){const e=this._data;let t,s=0,i=0;const n=1&e[this._pos];if(i=e[this._pos++],s|=127&i,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<7,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<14,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<21,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=268435456*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=34359738368*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=4398046511104*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(t=BigInt(s),i=e[this._pos++],t+=0x2000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);if(i=e[this._pos++],t+=0x100000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);if(i=e[this._pos++],t+=0x8000000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);throw new Error("Varint too long!")}_getLength(){if(this._dataType!==i.delimited)throw new Error("Not a delimited data type!");return this._decodeVarint()}_getLengthUnsafe(){return this.getUInt32()}_toString(e,t,s){if((s=Math.min(this._end,s))-t>c){const i=e.subarray(t,s);return h.decode(i)}let i="",n="";for(let r=t;r<s;++r){const t=e[r];128&t?n+="%"+t.toString(16):(i+=decodeURIComponent(n)+String.fromCharCode(t),n="")}return n.length&&(i+=decodeURIComponent(n)),i}_toBytes(e,t,s){return s=Math.min(this._end,s),new Uint8Array(e.buffer,t,s-t)}static{this.pool=new o.A(u,void 0,e=>{e._data=null,e._dataView=null})}}},87317:(e,t,s)=>{s.d(t,{a:()=>m,b:()=>g,c:()=>n,d:()=>c,e:()=>I,g:()=>a,h:()=>y,j:()=>d,l:()=>x,n:()=>p,s:()=>r,t:()=>_});var i=s(34304);function n(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function r(e,t,s,i,n){return e[0]=t,e[1]=s,e[2]=i,e[3]=n,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],i=t[1]-e[1],n=t[2]-e[2],r=t[3]-e[3];return Math.sqrt(s*s+i*i+n*n+r*r)}function f(e,t){const s=t[0]-e[0],i=t[1]-e[1],n=t[2]-e[2],r=t[3]-e[3];return s*s+i*i+n*n+r*r}function d(e){const t=e[0],s=e[1],i=e[2],n=e[3];return Math.sqrt(t*t+s*s+i*i+n*n)}function g(e){const t=e[0],s=e[1],i=e[2],n=e[3];return t*t+s*s+i*i+n*n}function p(e,t){const s=t[0],i=t[1],n=t[2],r=t[3];let a=s*s+i*i+n*n+r*r;return a>0&&(a=1/Math.sqrt(a),e[0]=s*a,e[1]=i*a,e[2]=n*a,e[3]=r*a),e}function y(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function x(e,t,s,i){const n=t[0],r=t[1],a=t[2],o=t[3];return e[0]=n+i*(s[0]-n),e[1]=r+i*(s[1]-r),e[2]=a+i*(s[2]-a),e[3]=o+i*(s[3]-o),e}function _(e,t,s){const i=t[0],n=t[1],r=t[2],a=t[3];return e[0]=s[0]*i+s[4]*n+s[8]*r+s[12]*a,e[1]=s[1]*i+s[5]*n+s[9]*r+s[13]*a,e[2]=s[2]*i+s[6]*n+s[10]*r+s[14]*a,e[3]=s[3]*i+s[7]*n+s[11]*r+s[15]*a,e}function m(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],n=e[1],r=e[2],a=e[3],o=t[0],l=t[1],h=t[2],c=t[3],u=(0,i.FD)();return Math.abs(s-o)<=u*Math.max(1,Math.abs(s),Math.abs(o))&&Math.abs(n-l)<=u*Math.max(1,Math.abs(n),Math.abs(l))&&Math.abs(r-h)<=u*Math.max(1,Math.abs(r),Math.abs(h))&&Math.abs(a-c)<=u*Math.max(1,Math.abs(a),Math.abs(c))}const b=o,M=l,w=h,k=u,T=f,A=d,P=g;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:n,copyVec3:function(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},dist:k,distance:u,div:w,divide:h,dot:y,equals:I,exactEquals:m,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:x,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:p,random:function(e,t=1){const s=i.Ov;let n,r,a,o,l,h;do{n=2*s()-1,r=2*s()-1,l=n*n+r*r}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*n,e[1]=t*r,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,i){return e[0]=t[0]+s[0]*i,e[1]=t[1]+s[1]*i,e[2]=t[2]+s[2]*i,e[3]=t[3]+s[3]*i,e},set:r,sqrDist:T,sqrLen:P,squaredDistance:f,squaredLength:g,str:function(e){return"vec4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"},sub:b,subtract:o,transformMat4:_,transformQuat:function(e,t,s){const i=t[0],n=t[1],r=t[2],a=s[0],o=s[1],l=s[2],h=s[3],c=h*i+o*r-l*n,u=h*n+l*i-a*r,f=h*r+a*n-o*i,d=-a*i-o*n-l*r;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"}))},91829:(e,t,s)=>{function i(){return[0,0,0,0]}function n(e){return[e[0],e[1],e[2],e[3]]}function r(e,t,s,i){return[e,t,s,i]}function a(e,t,s,i){return[e,t,s,i]}function o(e,t=[0,0,0,0]){const s=Math.min(4,e.length);for(let i=0;i<s;++i)t[i]=e[i];return t}function l(){return r(1,1,1,1)}function h(){return r(1,0,0,0)}function c(){return r(0,1,0,0)}function u(){return r(0,0,1,0)}function f(){return r(0,0,0,1)}s.d(t,{CN:()=>a,Un:()=>g,ci:()=>o,fA:()=>r,o8:()=>n,uY:()=>d,vt:()=>i});const d=[0,0,0,0],g=l(),p=h(),y=c(),x=u(),_=f();Object.freeze(Object.defineProperty({__proto__:null,ONES:g,UNIT_W:_,UNIT_X:p,UNIT_Y:y,UNIT_Z:x,ZEROS:d,clone:n,create:i,freeze:a,fromArray:o,fromValues:r,ones:l,unitW:f,unitX:h,unitY:c,unitZ:u,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"}))}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3379],{11764:(e,t,s)=>{s.r(t),s.d(t,{default:()=>ee});var i=s(74887),n=s(89640),r=s(6774),a=s(83027),o=s(13195);function l(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 h(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 c(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 u(e){switch(e){case 9:case 10:case 11:case 12:case 13:case 32:return!0}return!1}var f=s(18989);const d=24;class g{constructor(e,t,s,i,n,r,a){this._glyphItems=e,this._maxWidth=t,this._lineHeight=s,this._letterSpacing=i,this._hAnchor=n,this._vAnchor=r,this._justify=a}getShaping(e,t,s){const i=this._letterSpacing,n=this._lineHeight,r=this._justify,a=this._maxWidth,o=[];let f=0,d=0;for(const t of e){const e=t.codePointAt(0);if(null==e)continue;const n=s&&l(e);let r;for(const t of this._glyphItems)if(r=t[e],r)break;o.push({codePoint:e,x:f,y:d,vertical:n,glyphMosaicItem:r}),r&&(f+=r.metrics.advance+i)}let g=f;a>0&&(g=f/Math.max(1,Math.ceil(f/a)));const p=e.includes(""),y=[],x=o.length;for(let e=0;e<x-1;e++){const t=o[e].codePoint,s=h(t);if(c(t)||s){let i=0;if(10===t)i-=1e4;else if(s&&p)i+=150;else{40!==t&&65288!==t||(i+=50);const s=o[e+1].codePoint;41!==s&&65289!==s||(i+=50)}y.push(this._buildBreak(e+1,o[e].x,g,y,i,!1))}}const _=this._optimalBreaks(this._buildBreak(x,f,g,y,0,!0));let m=0;const I=t?-n:n;let b=0;for(let e=0;e<_.length;e++){const t=_[e];let s=b;for(;s<t&&u(o[s].codePoint);)o[s].glyphMosaicItem=null,++s;let i=t-1;for(;i>s&&u(o[i].codePoint);)o[i].glyphMosaicItem=null,--i;if(s<=i){const e=o[s].x;for(let t=s;t<=i;t++)o[t].x-=e,o[t].y=d;let t=o[i].x;o[i].glyphMosaicItem&&(t+=o[i].glyphMosaicItem.metrics.advance),m=Math.max(t,m),r&&this._applyJustification(o,s,i)}b=t,d+=I}if(o.length>0){const e=_.length-1,s=(r-this._hAnchor)*m;let i=(-this._vAnchor*(e+1)+.5)*n;t&&e&&(i+=e*n);for(const e of o)e.x+=s,e.y+=i}return o.filter(e=>e.glyphMosaicItem)}static getTextBox(e,t){if(!e.length)return null;let s=1/0,i=1/0,n=0,r=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),n=Math.max(n,h),i=Math.min(i,l),r=Math.max(r,c)}return{x:s,y:i,width:n-s,height:r-i}}static getBox(e){if(!e.length)return null;let t=1/0,s=1/0,i=0,n=0;for(const r of e){const{height:e,left:a,top:o,width:l}=r.glyphMosaicItem.metrics,h=r.x,c=r.y-(e-Math.abs(o)),u=h+l+a,f=c+e;t=Math.min(t,h),i=Math.max(i,u),s=Math.min(s,c),n=Math.max(n,f)}return{x:t,y:s,width:i-t,height:n-s}}static addDecoration(e,t){const s=e.length;if(0===s)return;let i=e[0].x+e[0].glyphMosaicItem.metrics.left,n=e[0].y;for(let r=1;r<s;r++){const s=e[r];if(s.y!==n){const a=e[r-1].x+e[r-1].glyphMosaicItem.metrics.left+e[r-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:i,y:n+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new f.A(4,0,4,8),metrics:{width:a-i,height:8,left:0,top:0,advance:0},page:0,code:0}}),n=s.y,i=s.x+s.glyphMosaicItem.metrics.left}}const r=e[s-1].x+e[s-1].glyphMosaicItem.metrics.left+e[s-1].glyphMosaicItem.metrics.width;e.push({codePoint:0,x:i,y:n+t-3,vertical:!1,glyphMosaicItem:{sdf:!0,rect:new f.A(4,0,4,8),metrics:{width:r-i,height:8,left:0,top:0,advance:0},page:0,code:0}})}_breakScore(e,t,s,i){const n=(e-t)*(e-t);return i?e<t?n/2:2*n:n+Math.abs(s)*s}_buildBreak(e,t,s,i,n,r){let a=null,o=this._breakScore(t,s,n,r);for(const e of i){const i=t-e.x,l=this._breakScore(i,s,n,r)+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 i=e[s],n=i.vertical?d:i.glyphMosaicItem?i.glyphMosaicItem.metrics.advance:0,r=(i.x+n)*this._justify;for(let i=t;i<=s;i++)e[i].x-=r}}var p=s(4272);const y=.5;class x{constructor(e,t,s=0,i=-1,n=y){this.x=e,this.y=t,this.angle=s,this.segment=i,this.minzoom=n}}class _{constructor(e,t,s,i,n,r=y,a=o.MG){this.anchor=e,this.labelAngle=t,this.glyphAngle=s,this.page=i,this.alternateVerticalGlyph=n,this.minzoom=r,this.maxzoom=a}}class m{constructor(e,t,s,i,n,r,a,o,l,h,c,u){this.tl=e,this.tr=t,this.bl=s,this.br=i,this.mosaicRect=n,this.labelAngle=r,this.minAngle=a,this.maxAngle=o,this.anchor=l,this.minzoom=h,this.maxzoom=c,this.page=u}}class I{constructor(e){this.shapes=e}}class b{getIconPlacement(e,t,s){const i=new r.bR(e.x,e.y),n=s.rotationAlignment===p.I5.MAP,a=s.keepUpright;let l=s.rotate*o.os;n&&(l+=e.angle);const h=new I([]);return s.allowOverlap&&s.ignorePlacement||(h.iconColliders=[]),this._addIconPlacement(h,i,t,s,l),n&&a&&this._addIconPlacement(h,i,t,s,l+o.Jo),h}_addIconPlacement(e,t,s,i,n){const a=s.rasterizationScale,l=s.width/a,h=s.height/a,c=i.offset;let u=c[0],f=c[1];switch(i.anchor){case p.KI.CENTER:u-=l/2,f-=h/2;break;case p.KI.LEFT:f-=h/2;break;case p.KI.RIGHT:u-=l,f-=h/2;break;case p.KI.TOP:u-=l/2;break;case p.KI.BOTTOM:u-=l/2,f-=h;break;case p.KI.TOP_LEFT:break;case p.KI.BOTTOM_LEFT:f-=h;break;case p.KI.TOP_RIGHT:u-=l;break;case p.KI.BOTTOM_RIGHT:u-=l,f-=h}const d=s.rect,g=2/a,x=u-g,_=f-g,I=x+d.width/a,b=_+d.height/a,M=new r.bR(x,_),w=new r.bR(I,b),k=new r.bR(x,b),T=new r.bR(I,_);if(0!==n){const e=Math.cos(n),t=Math.sin(n);M.rotate(e,t),w.rotate(e,t),k.rotate(e,t),T.rotate(e,t)}const A=new m(M,T,k,w,d,n,0,256,t,y,o.MG,0);if(e.shapes.push(A),!i.allowOverlap||!i.ignorePlacement){const s=i.size,r=i.padding,a={xTile:t.x,yTile:t.y,dxPixels:u*s-r,dyPixels:f*s-r,hard:!i.optional,partIndex:0,width:l*s+2*r,height:h*s+2*r,angle:n,minLod:y,maxLod:o.MG};e.iconColliders.push(a)}}getTextPlacement(e,t,s,i){const n=new r.bR(e.x,e.y),l=i.rotate*o.os,h=i.rotationAlignment===p.I5.MAP,c=i.keepUpright,u=i.padding;let f=y;const x=h?e.angle:0,b=e.segment>=0&&h,M=i.allowOverlap&&i.ignorePlacement?null:[],w=[],k=!b;let T=Number.POSITIVE_INFINITY,A=Number.NEGATIVE_INFINITY,P=T,D=A;const L=(b||h)&&c,V=i.size/d;let B=!1;for(const e of t)if(e.vertical){B=!0;break}let v,R=0,S=0;if(!b&&B){const e=g.getTextBox(t,i.lineHeight*d);switch(i.anchor){case p.KI.LEFT:R=e.height/2,S=-e.width/2;break;case p.KI.RIGHT:R=-e.height/2,S=e.width/2;break;case p.KI.TOP:R=e.height/2,S=e.width/2;break;case p.KI.BOTTOM:R=-e.height/2,S=-e.width/2;break;case p.KI.TOP_LEFT:R=e.height;break;case p.KI.BOTTOM_LEFT:S=-e.width;break;case p.KI.TOP_RIGHT:S=e.width;break;case p.KI.BOTTOM_RIGHT:R=-e.height}}R+=i.offset[0]*d,S+=i.offset[1]*d;for(const d of t){const t=d.glyphMosaicItem;if(!t||t.rect.isEmpty)continue;const g=t.rect,p=t.metrics,I=t.page;if(M&&k){if(void 0!==v&&v!==d.y){let t,s,n,r;B?(t=-D+R,s=T+S,n=D-P,r=A-T):(t=T+R,s=P+S,n=A-T,r=D-P);const a={xTile:e.x,yTile:e.y,dxPixels:t*V-u,dyPixels:s*V-u,hard:!i.optional,partIndex:1,width:n*V+2*u,height:r*V+2*u,angle:l,minLod:y,maxLod:o.MG};M.push(a),T=Number.POSITIVE_INFINITY,A=Number.NEGATIVE_INFINITY,P=T,D=A}v=d.y}const C=[];if(b){const i=.5*t.metrics.width,n=(d.x+p.left-4+i)*V*a.ih;if(f=this._placeGlyph(e,f,n,s,e.segment,1,d.vertical,I,C),c&&(f=this._placeGlyph(e,f,n,s,e.segment,-1,d.vertical,I,C)),f>=2)break}else C.push(new _(n,x,x,I,!1)),h&&c&&C.push(new _(n,x+o.Jo,x+o.Jo,I,!1));const E=d.x+p.left,O=d.y-17-p.top,F=E+p.width,N=O+p.height;let U,z,G,K,q,H,W,j;if(!b&&B)if(d.vertical){const e=(E+F)/2-p.height/2,t=(O+N)/2+p.width/2;U=new r.bR(-t-4+R,e-4+S),z=new r.bR(U.x+g.width,U.y+g.height),G=new r.bR(U.x,z.y),K=new r.bR(z.x,U.y)}else U=new r.bR(4-O+R,E-4+S),z=new r.bR(U.x-g.height,U.y+g.width),G=new r.bR(z.x,U.y),K=new r.bR(U.x,z.y);else U=new r.bR(E-4+R,O-4+S),z=new r.bR(U.x+g.width,U.y+g.height),G=new r.bR(U.x,z.y),K=new r.bR(z.x,U.y);for(const t of C){let s,n,a,o;if(t.alternateVerticalGlyph){if(!q){const e=(O+N)/2+S;q=new r.bR((E+F)/2+R-p.height/2-4,e+p.width/2+4),H=new r.bR(q.x+g.height,q.y-g.width),W=new r.bR(H.x,q.y),j=new r.bR(q.x,H.y)}s=q,n=W,a=j,o=H}else s=U,n=G,a=K,o=z;const h=O,c=N,f=t.glyphAngle+l;if(0!==f){const e=Math.cos(f),t=Math.sin(f);s=s.clone(),n=n?.clone(),a=a?.clone(),o=o?.clone(),s.rotate(e,t),o?.rotate(e,t),n?.rotate(e,t),a?.rotate(e,t)}let y=0,x=256;if(b&&B?d.vertical?t.alternateVerticalGlyph?(y=32,x=96):(y=224,x=32):(y=224,x=96):(y=192,x=64),w.push(new m(s,a,n,o,g,t.labelAngle,y,x,t.anchor,t.minzoom,t.maxzoom,t.page)),M&&(!L||this._legible(t.labelAngle)))if(k)E<T&&(T=E),h<P&&(P=h),F>A&&(A=F),c>D&&(D=c);else if(t.minzoom<2){const s={xTile:e.x,yTile:e.y,dxPixels:(E+R)*V-u,dyPixels:(h+R)*V-u,hard:!i.optional,partIndex:1,width:(F-E)*V+2*u,height:(c-h)*V+2*u,angle:f,minLod:t.minzoom,maxLod:t.maxzoom};M.push(s)}}}if(f>=2)return null;if(M&&k){let t,s,n,r;B?(t=-D+R,s=T+S,n=D-P,r=A-T):(t=T+R,s=P+S,n=A-T,r=D-P);const a={xTile:e.x,yTile:e.y,dxPixels:t*V-u,dyPixels:s*V-u,hard:!i.optional,partIndex:1,width:n*V+2*u,height:r*V+2*u,angle:l,minLod:y,maxLod:o.MG};M.push(a)}const C=new I(w);return M&&M.length>0&&(C.textColliders=M),C}_legible(e){const t=(0,o.z0)(e);return t<65||t>=193}_placeGlyph(e,t,s,i,n,a,l,h,c){let u=a;const f=u<0?(0,o.Wh)(e.angle+o.Jo,o.pJ):e.angle;let d=0;s<0&&(u*=-1,s*=-1,d=o.Jo),u>0&&++n;let g=new r.bR(e.x,e.y),p=i[n],y=o.MG;if(i.length<=n)return y;for(;;){const e=p.x-g.x,r=p.y-g.y,a=Math.sqrt(e*e+r*r),x=Math.max(s/a,t),m=e/a,I=r/a,b=(0,o.Wh)(Math.atan2(I,m)+d,o.pJ);if(c.push(new _(g,f,b,h,!1,x,y)),l&&c.push(new _(g,f,b,h,!0,x,y)),x<=t)return x;g=p.clone();do{if(n+=u,i.length<=n||n<0)return x;p=i[n]}while(g.isEqual(p));let M=p.x-g.x,w=p.y-g.y;const k=Math.sqrt(M*M+w*w);M*=a/k,w*=a/k,g.x-=M,g.y-=w,y=x}}}var M,w,k=s(51624),T=s(15585);(w=M||(M={}))[w.moveTo=1]="moveTo",w[w.lineTo=2]="lineTo",w[w.close=7]="close";class A{constructor(e,t,s=0){this.values={},this._geometry=void 0,this._pbfGeometry=null,this.featureIndex=s;const i=t.keys,n=t.values,r=e.asUnsafe();for(;r.next();)switch(r.tag()){case 1:this.id=r.getUInt64();break;case 2:{const e=r.getMessage().asUnsafe(),t=this.values;for(;!e.empty();){const s=e.getUInt32(),r=e.getUInt32();t[i[s]]=n[r]}e.release();break}case 3:this.type=r.getUInt32();break;case 4:this._pbfGeometry=r.getMessage();break;default:r.skip()}}getGeometry(e){if(void 0!==this._geometry)return this._geometry;if(!this._pbfGeometry)return null;const t=this._pbfGeometry.asUnsafe();let s,i;this._pbfGeometry=null,e?e.reset(this.type):s=[];let n,a=M.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 M.moveTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.moveTo(l,h):s&&(i&&s.push(i),i=[],i.push(new r.bR(l,h)));break;case M.lineTo:l+=t.getSInt32(),h+=t.getSInt32(),e?e.lineTo(l,h):i&&i.push(new r.bR(l,h));break;case M.close:e?e.close():i&&!i[0].equals(l,h)&&i.push(i[0].clone());break;default:throw t.release(),new Error("Invalid path operation")}}return e?n=e.result():s&&(i&&s.push(i),n=s),t.release(),this._geometry=n,n}}var P=s(80081);class D extends P.A{constructor(){super(12)}add(e,t,s){const i=this.array;i.push(e),i.push(t),i.push(s)}}P.A;class L{constructor(e){this.extent=a.vA,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(L._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 V extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a,o,l,h,c,u){const f=this.array;let d=P.A.i1616to32(e,t);f.push(d);const g=31;d=P.A.i8888to32(Math.round(g*s),Math.round(g*i),Math.round(g*n),Math.round(g*r)),f.push(d),d=P.A.i8888to32(Math.round(g*a),Math.round(g*o),Math.round(g*l),Math.round(g*h)),f.push(d),d=P.A.i1616to32(c,0),f.push(d),u&&f.push(...u)}}class B extends P.A{constructor(e){super(e)}add(e,t,s){const i=this.array;i.push(P.A.i1616to32(e,t)),s&&i.push(...s)}}class v extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a){const o=this.array,l=this.index;let h=P.A.i1616to32(e,t);return o.push(h),h=P.A.i8888to32(Math.round(15*s),Math.round(15*i),n,r),o.push(h),a&&o.push(...a),l}}class R extends P.A{constructor(e){super(e)}add(e,t,s,i,n,r,a,l,h,c,u,f){const d=this.array;let g=P.A.i1616to32(e,t);d.push(g),g=P.A.i1616to32(Math.round(8*s),Math.round(8*i)),d.push(g),g=P.A.i8888to32(n/4,r/4,l,h),d.push(g),g=P.A.i8888to32(0,(0,o.z0)(a),10*c,Math.min(10*u,255)),d.push(g),f&&d.push(...f)}}class S extends P.A{constructor(e){super(e)}add(e,t,s,i,n){const r=this.array,a=P.A.i1616to32(2*e+s,2*t+i);r.push(a),n&&r.push(...n)}}class C{constructor(e,t,s){this.layerExtent=a.vA,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 E extends C{constructor(e,t,s,i,r){super(e,t,s),this.type=n.NP.CIRCLE,this._circleVertexBuffer=i,this._circleIndexBuffer=r}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 i=this.layer,n=this.zoom;e&&e.setExtent(this.layerExtent);for(const r of this._features){const a=r.getGeometry(e);if(!a)continue;const o=i.circleMaterial.encodeAttributes(r,n,i);for(const e of a)if(e)for(const i of e){const e=t.index;t.add(i.x,i.y,0,0,o),t.add(i.x,i.y,0,1,o),t.add(i.x,i.y,1,0,o),t.add(i.x,i.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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._circleIndexStart,t[i++]=this._circleIndexCount,t[i++]=this._circleVertexBuffer.array.length;for(let e=0;e<this._circleVertexBuffer.array.length;e++)s[i++]=this._circleVertexBuffer.array[e];t[i++]=this._circleIndexBuffer.array.length;for(let e=0;e<this._circleIndexBuffer.array.length;e++)t[i++]=this._circleIndexBuffer.array[e];return t.buffer}}var O=s(98291),F=s(83349);class N extends C{constructor(e,t,s,i,r,a,o){super(e,t,s),this.type=n.NP.FILL,this._patternMap=new Map,this._fillVertexBuffer=i,this._fillIndexBuffer=r,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 i=this.layer,n=this.zoom,r=i.getPaintProperty("fill-pattern");if(r)if(r.isDataDriven)for(const e of this._features)t(r.getValue(n,e),!0);else t(r.getValue(n),!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:i,outlineMaterial:n,hasDataDrivenFill:r,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),i=t.getPaintValue("fill-opacity",s+1);e<1&&i<1&&(h=!1)}if(h&&!t.hasDataDrivenColor){const e=t.getPaintValue("fill-color",s),i=t.getPaintValue("fill-color",s+1);e[3]<1&&i[3]<1&&(h=!1)}}const c=this._features,u=e?.validateTessellation;if(l){const r=[];for(const l of c){const c=o.getValue(s,l),f=this._spriteInfo[c];if(!f?.rect)continue;const d=i.encodeAttributes(l,s,t,f),g=h&&a?n.encodeAttributes(l,s,t):[],p=l.getGeometry(e);r.push({ddFillAttributes:d,ddOutlineAttributes:g,page:f.page,geometry:p}),r.sort((e,t)=>e.page-t.page);for(const{ddFillAttributes:e,ddOutlineAttributes:s,page:i,geometry:n}of r)this._processFeature(n,h,t.outlineUsesFillColor,e,s,u,i)}}else for(const o of c){const l=r?i.encodeAttributes(o,s,t):null,c=h&&a?n.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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._fillIndexStart,t[i++]=this._fillIndexCount,t[i++]=this._outlineIndexStart,t[i++]=this._outlineIndexCount;const n=this._patternMap,r=n.size;if(t[i++]=r,r>0)for(const[e,[s,r]]of n)t[i++]=e,t[i++]=s,t[i++]=r;t[i++]=this._fillVertexBuffer.array.length;for(let e=0;e<this._fillVertexBuffer.array.length;e++)s[i++]=this._fillVertexBuffer.array[e];t[i++]=this._fillIndexBuffer.array.length;for(let e=0;e<this._fillIndexBuffer.array.length;e++)t[i++]=this._fillIndexBuffer.array[e];t[i++]=this._outlineVertexBuffer.array.length;for(let e=0;e<this._outlineVertexBuffer.array.length;e++)s[i++]=this._outlineVertexBuffer.array[e];t[i++]=this._outlineIndexBuffer.array.length;for(let e=0;e<this._outlineIndexBuffer.array.length;e++)t[i++]=this._outlineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s,i,n,r,a){if(!e)return;const o=e.length,l=!n||0===n.length;if(t&&(!s||l))for(let t=0;t<o;t++)this._processOutline(e[t],n);let h;for(let t=0;t<o;t++){const s=N._area(e[t]);s>32?(void 0!==h&&this._processFill(e,h,i,r,a),h=[t]):s<-32&&void 0!==h&&h.push(t)}void 0!==h&&this._processFill(e,h,i,r,a)}_processOutline(e,t){const s=this._outlineVertexBuffer,i=this._outlineIndexBuffer,n=i.index;let a,o,l;const h=new r.bR(0,0),c=new r.bR(0,0),u=new r.bR(0,0);let f=-1,d=-1,g=-1,p=-1,y=-1,x=!1,_=e.length;if(_<2)return;const m=e[0];let I=e[_-1];for(;_&&I.isEqual(m);)--_,I=e[_-1];if(!(_-0<2)){for(let n=0;n<_;++n){0===n?(a=e[_-1],o=e[0],l=e[1],h.assignSub(o,a),h.normalize(),h.rightPerpendicular()):(a=o,o=l,l=n!==_-1?e[n+1]:e[0],h.assign(c));const r=this._isClipEdge(a,o);-1===p&&(x=r),c.assignSub(l,o),c.normalize(),c.rightPerpendicular();const m=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),m>=0?(g=s.add(o.x,o.y,h.x,h.y,0,1,t),-1===p&&(p=g),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,b*-u.x,b*-u.y,0,-1,t),-1===y&&(y=d),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=d,d=g,g=s.add(o.x,o.y,u.x,u.y,0,1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,c.x,c.y,0,1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g)):(g=s.add(o.x,o.y,b*u.x,b*u.y,0,1,t),-1===p&&(p=g),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),d=s.add(o.x,o.y,-h.x,-h.y,0,-1,t),-1===y&&(y=d),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=d,d=g,g=s.add(o.x,o.y,-u.x,-u.y,0,-1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g),f=s.add(o.x,o.y,-c.x,-c.y,0,-1,t),f>=0&&d>=0&&g>=0&&!r&&i.add(f,d,g))}f>=0&&d>=0&&p>=0&&!x&&i.add(f,d,p),f>=0&&p>=0&&y>=0&&!x&&i.add(f,y,p),this._outlineIndexCount+=3*(i.index-n)}}_processFill(e,t,s,i,n){let r;t.length>1&&(r=[]);let a=0;for(const s of t)0!==a&&r.push(a),a+=e[s].length;const o=2*a,l=O.A.acquire();for(const s of t){const t=e[s],i=t.length;for(let e=0;e<i;++e)l.push(t[e].x,t[e].y)}const h=(0,F.e)(l,r,2);if(F.e.deviation(l,r,2,h)>0){const i=t.map(t=>e[t].length),{buffer:r,vertexCount:a}=(0,T.l)(l,i);if(a>0){const e=this._fillVertexBuffer.index;for(let e=0;e<a;e++)this._fillVertexBuffer.add(r[2*e],r[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!==n){const e=this._patternMap,t=e.get(n);t?t[1]+=a:e.set(n,[this._fillIndexStart+this._fillIndexCount,a])}this._fillIndexCount+=a}}else{const e=h.length;if(e>0){const t=this._fillVertexBuffer.index;let i=0;for(;i<o;)this._fillVertexBuffer.add(l[i++],l[i++],s);let r=0;for(;r<e;)this._fillIndexBuffer.add(t+h[r++],t+h[r++],t+h[r++]);if(void 0!==n){const t=this._patternMap,s=t.get(n);s?s[1]+=e:t.set(n,[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 i=0;i<s;i++)t+=(e[i].x-e[i+1].x)*(e[i].y+e[i+1].y);return t+=(e[s].x-e[0].x)*(e[s].y+e[0].y),.5*t}}var U=s(83773);class z extends C{constructor(e,t,s,i,r){super(e,t,s),this.type=n.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=i,this.tessellationProperties._lineIndexBuffer=r,this._lineTessellator=new U.i(G(this.tessellationProperties),K(this.tessellationProperties),e.canUseThinTessellation)}get lineIndexStart(){return this._lineIndexStart}get lineIndexCount(){return this._lineIndexCount}getResources(e,t,s){const i=this.layer,n=this.zoom,r=i.getPaintProperty("line-pattern"),a=i.getPaintProperty("line-dasharray"),o=i.getLayoutProperty("line-cap");if(!r&&!a)return;const l=o?.getValue(n)||0,h=o?.isDataDriven,c=r?.isDataDriven,u=a?.isDataDriven;if(c||u)for(const e of this._features)t(c?r.getValue(n,e):this._getDashArrayKey(e,n,i,a,h,o,l));else if(r)t(r.getValue(n));else if(a){const e=a.getValue(n);t(i.getDashKey(e,l))}}processFeatures(e){this._lineIndexStart=3*this.tessellationProperties._lineIndexBuffer.index,this._lineIndexCount=0;const t=this.layer,s=this.zoom,i=this._features,n=this._tessellationOptions,{hasDataDrivenLine:r,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),g=d||0,p=!!f;u=t.getLayoutProperty("line-join");const y=u?.isDataDriven?u:null,x=y?null:t.getLayoutValue("line-join",s);u=t.getLayoutProperty("line-miter-limit");const _=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 k=u?.isDataDriven?u:null,T=k?null:t.getPaintValue("line-offset",s);if(h||c){const r=[];for(const n of i){const i=h?o.getValue(s,n):this._getDashArrayKey(n,s,t,l,p,f,g),c=this._spriteInfo[i];if(!c?.rect)continue;const u=a.encodeAttributes(n,s,t,c),A=n.getGeometry(e);r.push({ddAttributes:u,page:c.page,cap:f?f.getValue(s,n):d,join:y?y.getValue(s,n):x,miterLimit:_?_.getValue(s,n):m,roundLimit:I?I.getValue(s,n):b,halfWidth:.5*(M?M.getValue(s,n):w),offset:k?k.getValue(s,n):T,geometry:A})}r.sort((e,t)=>e.page-t.page),n.textured=!0;for(const{ddAttributes:e,page:t,cap:s,join:i,miterLimit:a,roundLimit:o,halfWidth:l,offset:h,geometry:c}of r)n.capType=s,n.joinType=i,n.miterLimit=a,n.roundLimit=o,n.halfWidth=l,n.offset=h,this._processFeature(c,e,t)}else{if(o){const e=o.getValue(s),t=this._spriteInfo[e];if(!t?.rect)return}n.textured=!(!o&&!l),n.capType=d,n.joinType=x,n.miterLimit=m,n.roundLimit=b,n.halfWidth=.5*w,n.offset=T;for(const o of i){const i=r?a.encodeAttributes(o,s,t):null;f&&(n.capType=f.getValue(s,o)),y&&(n.joinType=y.getValue(s,o)),_&&(n.miterLimit=_.getValue(s,o)),I&&(n.roundLimit=I.getValue(s,o)),M&&(n.halfWidth=.5*M.getValue(s,o)),k&&(n.offset=k.getValue(s,o));const l=o.getGeometry(e);this._processFeature(l,i)}}}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 i=0;t[i++]=this.type,t[i++]=this.layerUIDs.length;for(let e=0;e<this.layerUIDs.length;e++)t[i++]=this.layerUIDs[e];t[i++]=this._lineIndexStart,t[i++]=this._lineIndexCount;const n=this._patternMap,r=n.size;if(t[i++]=r,r>0)for(const[e,[s,r]]of n)t[i++]=e,t[i++]=s,t[i++]=r;t[i++]=this.tessellationProperties._lineVertexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineVertexBuffer.array.length;e++)s[i++]=this.tessellationProperties._lineVertexBuffer.array[e];t[i++]=this.tessellationProperties._lineIndexBuffer.array.length;for(let e=0;e<this.tessellationProperties._lineIndexBuffer.array.length;e++)t[i++]=this.tessellationProperties._lineIndexBuffer.array[e];return t.buffer}_processFeature(e,t,s){if(!e)return;const i=e.length;for(let n=0;n<i;n++)this._processGeometry(e[n],t,s)}_processGeometry(e,t,s){if(e.length<2)return;let i,n,r=e[0],a=1;for(;a<e.length;)i=e[a].x-r.x,n=e[a].y-r.y,i*i+n*n<1e-6?e.splice(a,1):(r=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,i,n,r,a){const o=n?r.getValue(t,e):a,l=i.getValue(t,e);return s.getDashKey(l,o)}}const G=e=>(t,s,i,n,r,a,o,l,h,c,u)=>(e._lineVertexBuffer.add(t,s,o,l,i,n,r,a,h,c,u,e._ddValues),e._lineVertexBuffer.index-1),K=e=>(t,s,i)=>{e._lineIndexBuffer.add(t,s,i)};var q,H=s(32488),W=s(97768),j=s(799),Y=s(3057);function J(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 Z extends C{constructor(e,t,s,i,r,a,o,l,h){super(t,s,h.getSpriteItems()),this.type=n.NP.SYMBOL,this._markerMap=new Map,this._glyphMap=new Map,this._glyphBufferDataStorage=new Map,this._isIconSDF=!1,this._sourceTileKey=e,this._iconVertexBuffer=i,this._iconIndexBuffer=r,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}static{this._bidiEngine=new H.A}getResources(e,t,s){const i=this.layer,n=this.zoom;e&&e.setExtent(this.layerExtent);const r=i.getLayoutProperty("icon-image"),a=i.getLayoutProperty("text-field");let o=i.getLayoutProperty("text-transform"),l=i.getLayoutProperty("text-font");const h=[];let c,u,f,d;r&&!r.isDataDriven&&(c=r.getValue(n)),a&&!a.isDataDriven&&(u=a.getValue(n)),o&&o.isDataDriven||(f=i.getLayoutValue("text-transform",n),o=null),l&&l.isDataDriven||(d=i.getLayoutValue("text-font",n),l=null);for(const g of this._features){const y=g.getGeometry(e);if(!y||0===y.length)continue;let x,_;r&&(x=r.isDataDriven?r.getValue(n,g):this._replaceKeys(c,g.values),x&&t(x));let m=!1;if(a&&(_=a.isDataDriven?a.getValue(n,g):this._replaceKeys(u,g.values),_)){switch(_=_.replaceAll("\\n","\n"),o&&(f=o.getValue(n,g)),f){case p.Ms.LOWERCASE:_=_.toLowerCase();break;case p.Ms.UPPERCASE:_=_.toUpperCase()}if(Z._bidiEngine.hasBidiChar(_)){let e;e="rtl"===Z._bidiEngine.checkContextual(_)?"IDNNN":"ICNNN",_=Z._bidiEngine.bidiTransform(_,e,"VLYSN"),m=!0}if(_.length>0){l&&(d=l.getValue(n,g));for(const e of d){let t=s[e];t||(t=s[e]=new Set);for(const e of _){const s=e.codePointAt(0);null!=s&&t.add(s)}}}}if(!x&&!_)continue;const I=i.getLayoutValue("symbol-sort-key",n,g),b={feature:g,sprite:x,label:_,rtl:m,geometry:y,hash:(_?(0,j.Wm)(_):0)^(x?(0,j.Wm)(x):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,i=t.getLayoutValue("symbol-placement",s),n=i!==p.kt.POINT,l=t.getLayoutValue("symbol-spacing",s)*a.ih,h=t.getLayoutProperty("icon-image"),c=t.getLayoutProperty("text-field"),u=h?new Y.aR(t,s,n):null,f=c?new Y.uU(t,s,n):null,y=this._workerTileHandler;let _;h&&(_=y.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 I=1;f?.size&&(I=f.size/d);const b=f?f.maxAngle*o.os:0,M=f?f.size*a.ih:0;for(const e of this._symbolFeatures){let t,o;u&&_&&e.sprite&&(t=_[e.sprite],t&&t.sdf&&(this._isIconSDF=!0)),t&&u.update(s,e.feature);let h=0;const c=e.label;if(c){(0,W.Lw)(f),f.update(s,e.feature);const t=n&&f.rotationAlignment===p.I5.MAP?f.keepUpright:f.writingMode&&f.writingMode.includes(p.v9.VERTICAL);let i=.5;switch(f.anchor){case p.KI.TOP_LEFT:case p.KI.LEFT:case p.KI.BOTTOM_LEFT:i=0;break;case p.KI.TOP_RIGHT:case p.KI.RIGHT:case p.KI.BOTTOM_RIGHT:i=1}let r=.5;switch(f.anchor){case p.KI.TOP_LEFT:case p.KI.TOP:case p.KI.TOP_RIGHT:r=0;break;case p.KI.BOTTOM_LEFT:case p.KI.BOTTOM:case p.KI.BOTTOM_RIGHT:r=1}let l=.5;switch(f.justify){case p.O6.AUTO:l=i;break;case p.O6.LEFT:l=0;break;case p.O6.RIGHT:l=1}const u=f.letterSpacing*d,x=n?0:f.maxWidth*d,_=f.lineHeight*d,m=e.textFont.map(e=>y.getGlyphItems(e));if(o=new g(m,x,_,u,i,r,l).getShaping(c,e.rtl,t),o&&o.length>0){let e=1e30,t=-1e30;for(const s of o)e=Math.min(e,s.x),t=Math.max(t,s.x);h=(t-e+48)*I*a.ih}}for(let s of e.geometry){const c=[];if(i===p.kt.LINE){if(o?.length&&f?.size){const e=f.size*a.ih*(2+Math.min(2,4*Math.abs(f.offset[1])));s=Z._smoothVertices(s,e)}Z._pushAnchors(c,s,l,h)}else i===p.kt.LINE_CENTER?Z._pushCenterAnchor(c,s):e.feature.type===r.dC.Polygon?Z._pushCentroid(c,s):c.push(new x(s[0].x,s[0].y));for(const i of c){if(i.x<0||i.x>a.vA||i.y<0||i.y>a.vA)continue;if(n&&h>0&&f?.rotationAlignment===p.I5.MAP&&!Z._honorsTextMaxAngle(s,i,h,b,M))continue;const r={shaping:o,line:s,iconMosaicItem:t,anchor:i,symbolFeature:e,textColliders:[],iconColliders:[],textVertexRanges:[],iconVertexRanges:[]};m.push(r),this._processFeature(r,u,f)}}}m.sort(J),this._addPlacedGlyphs(),this._symbolInstances=m}serialize(){let e=14;e+=this.layerUIDs.length,e+=3*this.markerPageMap.size,e+=3*this.glyphsPageMap.size,e+=Z._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),i=new Float32Array(t.buffer),[n,r,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(n),t[o++]=parseFloat(r),t[o++]=parseFloat(a),t[o++]=this.markerPageMap.size;for(const[e,[s,i]]of this.markerPageMap)t[o++]=e,t[o++]=s,t[o++]=i;t[o++]=this.glyphsPageMap.size;for(const[e,[s,i]]of this.glyphsPageMap)t[o++]=e,t[o++]=s,t[o++]=i;t[o++]=this._iconVertexBuffer.index/4,t[o++]=this._textVertexBuffer.index/4,o=Z.serializeSymbols(t,s,i,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,i,n){n=n||[],t[i++]=n.length;for(const e of n){t[i++]=e.anchor.x,t[i++]=e.anchor.y,t[i++]=e.symbolFeature.hash,t[i++]=e.symbolFeature.priority,t[i++]=e.symbolFeature.feature.featureIndex,t[i++]=e.textColliders.length+e.iconColliders.length;for(const n of e.textColliders)t[i++]=n.xTile,t[i++]=n.yTile,t[i++]=n.dxPixels,t[i++]=n.dyPixels,t[i++]=n.hard?1:0,t[i++]=n.partIndex,s[i++]=n.minLod,s[i++]=n.maxLod,t[i++]=n.width,t[i++]=n.height;for(const n of e.iconColliders)t[i++]=n.xTile,t[i++]=n.yTile,t[i++]=n.dxPixels,t[i++]=n.dyPixels,t[i++]=n.hard?1:0,t[i++]=n.partIndex,s[i++]=n.minLod,s[i++]=n.maxLod,t[i++]=n.width,t[i++]=n.height;t[i++]=e.textVertexRanges.length;for(const[s,n]of e.textVertexRanges)t[i++]=s,t[i++]=n;t[i++]=e.iconVertexRanges.length;for(const[s,n]of e.iconVertexRanges)t[i++]=s,t[i++]=n}return i}_replaceKeys(e,t){return e.replaceAll(/{([^{}]+)}/g,(e,s)=>s in t?t[s]:"")}_processFeature(e,t,s){const{line:i,iconMosaicItem:n,shaping:r,anchor:a}=e,l=this.zoom,h=this.layer,c=!!n;let u=!0;c&&(u=t?.optional||!n);const f=r&&r.length>0,d=!f||s?.optional;let g,y;if(c&&(g=this._placementEngine.getIconPlacement(a,n,t)),(g||u)&&(f&&(y=this._placementEngine.getTextPlacement(a,r,i,s)),y||d)){if(g&&y||(d||u?d||y?u||g||(y=null):g=null:(g=null,y=null)),y){const t=h.hasDataDrivenText?h.textMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._storePlacedGlyphs(e,y.shapes,l,s.rotationAlignment,t),y.textColliders){e.textColliders=y.textColliders;for(const e of y.textColliders){e.minLod=Math.max(l+(0,o.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,o.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),i=Math.sin(t),n=e.dxPixels*s-e.dyPixels*i,r=e.dxPixels*i+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*i,o=(e.dxPixels+e.width)*i+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*i,h=e.dxPixels*i+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*i,u=(e.dxPixels+e.width)*i+(e.dyPixels+e.height)*s,f=Math.min(n,a,l,c),d=Math.max(n,a,l,c),g=Math.min(r,o,h,u),p=Math.max(r,o,h,u);e.dxPixels=f,e.dyPixels=g,e.width=d-f,e.height=p-g}}}}if(g){const s=h.hasDataDrivenIcon?h.iconMaterial.encodeAttributes(e.symbolFeature.feature,l,h):null;if(this._addPlacedIcons(e,g.shapes,l,n.page,t.rotationAlignment===p.I5.VIEWPORT,s),g.iconColliders){e.iconColliders=g.iconColliders;for(const e of g.iconColliders){e.minLod=Math.max(l+(0,o.p6)(e.minLod),0),e.maxLod=Math.min(l+(0,o.p6)(e.maxLod),25);const t=e.angle;if(t){const s=Math.cos(t),i=Math.sin(t),n=e.dxPixels*s-e.dyPixels*i,r=e.dxPixels*i+e.dyPixels*s,a=(e.dxPixels+e.width)*s-e.dyPixels*i,o=(e.dxPixels+e.width)*i+e.dyPixels*s,l=e.dxPixels*s-(e.dyPixels+e.height)*i,h=e.dxPixels*i+(e.dyPixels+e.height)*s,c=(e.dxPixels+e.width)*s-(e.dyPixels+e.height)*i,u=(e.dxPixels+e.width)*i+(e.dyPixels+e.height)*s,f=Math.min(n,a,l,c),d=Math.max(n,a,l,c),g=Math.min(r,o,h,u),p=Math.max(r,o,h,u);e.dxPixels=f,e.dyPixels=g,e.width=d-f,e.height=p-g}}}}}}_addPlacedIcons(e,t,s,i,n,r){const a=Math.max(s-1,0),l=this._iconVertexBuffer,h=this._iconIndexBuffer,c=this._markerMap;for(const u of t){const t=n?0:Math.max(s+(0,o.p6)(u.minzoom),a),f=n?25:Math.min(s+(0,o.p6)(u.maxzoom),25);if(f<=t)continue;const d=u.tl,g=u.tr,p=u.bl,y=u.br,x=u.mosaicRect,_=u.labelAngle,m=u.minAngle,I=u.maxAngle,b=u.anchor,M=l.index,w=x.x,k=x.y,T=w+x.width,A=k+x.height,P=l.index;l.add(b.x,b.y,d.x,d.y,w,k,_,m,I,t,f,r),l.add(b.x,b.y,g.x,g.y,T,k,_,m,I,t,f,r),l.add(b.x,b.y,p.x,p.y,w,A,_,m,I,t,f,r),l.add(b.x,b.y,y.x,y.y,T,A,_,m,I,t,f,r),e.iconVertexRanges.length>0&&e.iconVertexRanges[0][0]+e.iconVertexRanges[0][1]===P?e.iconVertexRanges[0][1]+=4:e.iconVertexRanges.push([P,4]),h.add(M,M+1,M+2),h.add(M+1,M+2,M+3),c.has(i)?c.get(i)[1]+=6:c.set(i,[this._iconIndexStart+this._iconIndexCount,6]),this._iconIndexCount+=6}}_addPlacedGlyphs(){const e=this._textVertexBuffer,t=this._textIndexBuffer,s=this._glyphMap;for(const[i,n]of this._glyphBufferDataStorage)for(const r of n){const n=e.index,a=r.symbolInstance,o=r.ddAttributes,l=e.index;e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.tl[0],r.tl[1],r.xmin,r.ymin,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.tr[0],r.tr[1],r.xmax,r.ymin,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.bl[0],r.bl[1],r.xmin,r.ymax,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.maxLod,o),e.add(r.glyphAnchor[0],r.glyphAnchor[1],r.br[0],r.br[1],r.xmax,r.ymax,r.labelAngle,r.minAngle,r.maxAngle,r.minLod,r.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(n,n+1,n+2),t.add(n+1,n+2,n+3),s.has(i)?s.get(i)[1]+=6:s.set(i,[this._textIndexStart+this._textIndexCount,6]),this._textIndexCount+=6}this._glyphBufferDataStorage.clear()}_storePlacedGlyphs(e,t,s,i,n){const r=Math.max(s-1,0),a=i===p.I5.VIEWPORT;let l,h,c,u,f,d,g,y,x,_,m;for(const i of t)l=a?0:Math.max(s+(0,o.p6)(i.minzoom),r),h=a?25:Math.min(s+(0,o.p6)(i.maxzoom),25),h<=l||(c=i.tl,u=i.tr,f=i.bl,d=i.br,g=i.labelAngle,y=i.minAngle,x=i.maxAngle,_=i.anchor,m=i.mosaicRect,this._glyphBufferDataStorage.has(i.page)||this._glyphBufferDataStorage.set(i.page,[]),this._glyphBufferDataStorage.get(i.page).push({glyphAnchor:[_.x,_.y],tl:[c.x,c.y],tr:[u.x,u.y],bl:[f.x,f.y],br:[d.x,d.y],xmin:m.x,ymin:m.y,xmax:m.x+m.width,ymax:m.y+m.height,labelAngle:g,minAngle:y,maxAngle:x,minLod:l,maxLod:h,placementLod:r,symbolInstance:e,ddAttributes:n}))}static _pushAnchors(e,t,s,i){s+=i;let n=0;const a=t.length-1;for(let e=0;e<a;e++)n+=r.bR.distance(t[e],t[e+1]);let l=i||s;if(l*=.5,n<=l)return;const h=l/n;let c=0,u=-(s=n/Math.max(Math.round(n/s),1))/2;const f=t.length-1;for(let i=0;i<f;i++){const n=t[i],r=t[i+1],a=r.x-n.x,l=r.y-n.y,f=Math.sqrt(a*a+l*l);let d;for(;u+s<c+f;){u+=s;const t=(u-c)/f,g=(0,o.GW)(n.x,r.x,t),p=(0,o.GW)(n.y,r.y,t);void 0===d&&(d=Math.atan2(l,a)),e.push(new x(g,p,d,i,h))}c+=f}}static _pushCenterAnchor(e,t){let s=0;const i=t.length-1;for(let e=0;e<i;e++)s+=r.bR.distance(t[e],t[e+1]);const n=s/2;let a=0;const l=t.length-1;for(let s=0;s<l;s++){const i=t[s],r=t[s+1],l=r.x-i.x,h=r.y-i.y,c=Math.sqrt(l*l+h*h);if(n<a+c){const t=(n-a)/c,u=(0,o.GW)(i.x,r.x,t),f=(0,o.GW)(i.y,r.y,t),d=Math.atan2(h,l);return void e.push(new x(u,f,d,s,0))}a+=c}}static _deviation(e,t,s){const i=(t.x-e.x)*(s.x-t.x)+(t.y-e.y)*(s.y-t.y),n=(t.x-e.x)*(s.y-t.y)-(t.y-e.y)*(s.x-t.x);return Math.atan2(n,i)}static _honorsTextMaxAngle(e,t,s,i,n){let a=0;const o=s/2;let l=new r.bR(t.x,t.y),h=t.segment+1;for(;a>-o;){if(--h,h<0)return!1;a-=r.bR.distance(e[h],l),l=e[h]}a+=r.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 g=this._deviation(t,s,l);for(c.push({deviation:g,distToAnchor:a}),u+=g;a-c[0].distToAnchor>n;)u-=c.shift().deviation;if(Math.abs(u)>i)return!1;a+=r.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 i=[];let n=0,a=0;i.push(0);for(let t=1;t<s;t++){const s=r.bR.distance(e[t],e[t-1]);s>0&&(n+=s,i.push(n),a++,a!==t&&(e[a]=e[t]))}if(s=a+1,s<3)return e;t=Math.min(t,.2*n);const o=e[0].x,l=e[0].y,h=e[s-1].x,c=e[s-1].y,u=r.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,i[0]-=t,i[s-1]+=t;const f=[];f.push(new r.bR(o,l));const d=1e-6,g=.5*t;for(let n=1;n<s-1;n++){let a=0,o=0,l=0;for(let s=n-1;s>=0;s--){const r=g+i[s+1]-i[n];if(r<0)break;const h=i[s+1]-i[s],c=i[n]-i[s]<g?1:r/h;if(c<d)break;const u=c*c,f=c*r-.5*u*h,p=c*h/t,y=e[s+1],x=e[s].x-y.x,_=e[s].y-y.y;a+=p/f*(y.x*c*r+.5*u*(r*x-h*y.x)-u*c*h*x/3),o+=p/f*(y.y*c*r+.5*u*(r*_-h*y.y)-u*c*h*_/3),l+=p}for(let r=n+1;r<s;r++){const s=g-i[r-1]+i[n];if(s<0)break;const h=i[r]-i[r-1],c=i[r]-i[n]<g?1:s/h;if(c<d)break;const u=c*c,f=c*s-.5*u*h,p=c*h/t,y=e[r-1],x=e[r].x-y.x,_=e[r].y-y.y;a+=p/f*(y.x*c*s+.5*u*(s*x-h*y.x)-u*c*h*x/3),o+=p/f*(y.y*c*s+.5*u*(s*_-h*y.y)-u*c*h*_/3),l+=p}f.push(new r.bR(a/l,o/l))}return f.push(new r.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=a.vA,i=a.vA,n=t.length-1;let r=0,o=0,l=0,h=t[0].x,c=t[0].y;h>s&&(h=s),h<0&&(h=0),c>i&&(c=i),c<0&&(c=0);for(let e=1;e<n;e++){let n=t[e].x,a=t[e].y,u=t[e+1].x,f=t[e+1].y;n>s&&(n=s),n<0&&(n=0),a>i&&(a=i),a<0&&(a=0),u>s&&(u=s),u<0&&(u=0),f>i&&(f=i),f<0&&(f=0);const d=(n-h)*(f-c)-(u-h)*(a-c);r+=d*(h+n+u),o+=d*(c+a+f),l+=d}r/=3*l,o/=3*l,isNaN(r)||isNaN(o)||e.push(new x(r,o))}}!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"}(q||(q={}));class ${constructor(e,t,s,i,n,a){if(this._pbfTiles={},this._tileClippers={},this._client=s,this._tile=t,this._sourceDataMaxLOD=i,a){this._styleLayerUIDs=new Set;for(const e of a)this._styleLayerUIDs.add(e)}this._styleRepository=n,this._layers=this._styleRepository?.layers??[];const[l,h,c]=t.tileKey.split("/").map(parseFloat);this._level=l;const u=(0,o.IU)(this._level);for(const t of Object.keys(e)){const s=e[t];if(this._pbfTiles[t]=new k.A(new Uint8Array(s.protobuff),new DataView(s.protobuff)),s.refKey){const[e]=s.refKey.split("/").map(parseFloat),i=l-e;if(i>0){const e=(1<<i)-1,s=h&e,n=c&e;this._tileClippers[t]=new r.O3(i,s,n,8,u)}}this._tileClippers[t]||(this._tileClippers[t]=new r.Ox)}}_canParseStyleLayer(e){return!this._styleLayerUIDs||this._styleLayerUIDs.has(e)}async parse(e){const t=(0,T.F)(),s=this._initialize(e),{returnedBuckets:i}=s;this._processLayers(s),this._linkReferences(s),this._filterFeatures(s);const n=[],r=new Set,a=(e,t)=>{r.has(e)||(n.push({name:e,repeat:t}),r.add(e))},o={};for(const e of i)e.getResources(e.tileClipper,a,o);if(this._tile.status===q.INVALID)return[];const l=this._fetchResources(n,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:i,sourceNameToTileClipper:n,sourceNameToUniqueSourceLayerBuckets:r,sourceNameToUniqueSourceLayers:a,returnedBuckets:o,layerIdToBucket:l,referencerUIDToReferencedId:h}=e,c=this._sourceDataMaxLOD;for(let e=i.length-1;e>=0;e--){const u=i[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===p.Dc.BACKGROUND||!this._canParseStyleLayer(u.uid)||!t[u.source]||!n[u.source])continue;const f=t[u.source],d=n[u.source],g=u.sourceLayer,y=f[g];if(y){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=y.extent,e.tileClipper=d;let t=r[u.source];t||(t=r[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:n,sourceNameToUniqueSourceLayers:r}=e,a=10*this._level,o=10*(this._level+1),l=[],h=[];for(const e of Object.keys(r))r[e].forEach(t=>{l.push(t),h.push(e)});for(let e=0;e<l.length;e++){const r=h[e],c=l[e];if(!s[r]||!n[r])continue;const u=s[r][c],f=n[r][c];if(!f||0===f.length)continue;if((0,i.G4)(t))return;let d=0;const g=u.getData();for(;g.nextTag(2);){const e=g.getMessage(),t=new A(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 i=[],n=this._tile.getWorkerTileHandler();let r,a;e.length>0&&(r=n.fetchSprites(e,this._client,s),i.push(r));for(const e in t){const r=t[e];r.size>0&&(a=n.fetchGlyphs(this._tile.tileKey,e,r,this._client,s),i.push(a))}return i}_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 i=e[s],n={};for(;i.next();)switch(i.tag()){case 3:{const e=i.getMessage(),t=new L(e);e.release(),n[t.name]=t;break}default:i.skip()}t[s]=n}return t}_createBucket(e){switch(e.type){case p.Dc.BACKGROUND:return null;case p.Dc.FILL:return this._createFillBucket(e);case p.Dc.LINE:return this._createLineBucket(e);case p.Dc.CIRCLE:return this._createCircleBucket(e);case p.Dc.SYMBOL:return this._createSymbolBucket(e)}}_createFillBucket(e){return new N(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 z(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new V(e.lineMaterial.getStride()),new D)}_createCircleBucket(e){return new E(e,this._level,this._tile.getWorkerTileHandler().getSpriteItems(),new S(e.circleMaterial.getStride()),new D)}_createSymbolBucket(e){const t=this._tile;return new Z(t.tileKey,e,this._level,new R(e.iconMaterial.getStride()),new D,new R(e.textMaterial.getStride()),new D,t.placementEngine,t.getWorkerTileHandler())}}class Q{constructor(e,t,s,i){this.status=q.INITIALIZED,this.placementEngine=new b,this.tileKey=e,this.refKeys=t,this._workerTileHandler=s,this._styleRepository=i}release(){this.tileKey="",this.refKeys=null,this.status=q.INITIALIZED,this._workerTileHandler=null}async parse(e,t){const s=t?.signal;if(null!=s){const e=()=>{s.removeEventListener("abort",e),this.status=q.INVALID};s.addEventListener("abort",e)}let n;const r={bucketsWithData:[],emptyBuckets:null};try{n=await this._parse(e,t)}catch(e){if((0,i.zf)(e))throw e;return{result:r,transferList:[]}}this.status=q.READY;const a=r.bucketsWithData,o=[];for(const e of n)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)),r.emptyBuckets=h,{result:r,transferList:l}}setObsolete(){this.status=q.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=q.MODIFIED,new $(s,this,t.client,e.sourceDataMaxLOD,this._styleRepository,e.styleLayerUIDs).parse(t))}}var X=s(45013);class ee{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,n={};for(const t of Object.keys(e.sourceName2DataAndRefKey)){const s=e.sourceName2DataAndRefKey[t];n[t]=s.refKey}const r=new Q(s,n,this,this._styleRepository);try{return await r.parse({...e,sourceDataMaxLOD:this._sourceDataMaxLOD},t)}catch(e){if(r.setObsolete(),r.release(),!(0,i.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,i=s.data;switch(e){case n.$q.PAINTER_CHANGED:t.setPaintProperties(i.layer,i.paint);break;case n.$q.LAYOUT_CHANGED:t.setLayoutProperties(i.layer,i.layout);break;case n.$q.LAYER_REMOVED:t.deleteStyleLayer(i.layer);break;case n.$q.LAYER_CHANGED:t.setStyleLayer(i.layer,i.index);break;case n.$q.SPRITES_CHANGED:this._spriteInfo={}}}}setStyle(e){const{style:t,sourceDataMaxLOD:s}=e;this._styleRepository=new X.A(t),this._sourceDataMaxLOD=s,this._spriteInfo={},this._glyphInfo={}}fetchSprites(e,t,s){const i=[],n=this._spriteInfo;for(const t of e)void 0===n[t.name]&&i.push(t);return 0===i.length?Promise.resolve():t.invoke("getSprites",i,{signal:s?.signal}).then(e=>{for(const t in e){const s=e[t];n[t]=s}})}getSpriteItems(){return this._spriteInfo}fetchGlyphs(e,t,s,i,n){const r=[];let a=this._glyphInfo[t];return a?s.forEach(e=>{a[e]||r.push(e)}):(a=this._glyphInfo[t]=[],s.forEach(e=>r.push(e))),0===r.length?Promise.resolve():i.invoke("getGlyphs",{tileID:e,font:t,codePoints:r},n).then(e=>{for(let t=0;t<e.length;t++)e[t]&&(a[t]=e[t])})}getGlyphItems(e){return this._glyphInfo[e]}}},34304:(e,t,s)=>{s.d(t,{DF:()=>l,FD:()=>n,Ov:()=>r,ct:()=>h});let i=1e-6;function n(){return i}const r=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:r,equals:function(e,t){return Math.abs(e-t)<=i*Math.max(1,Math.abs(e),Math.abs(t))},getEpsilon:n,setEpsilon:function(e){i=e},toDegree:h,toRadian:l},Symbol.toStringTag,{value:"Module"}))},40876:(e,t,s)=>{s.d(t,{Eq:()=>d,G1:()=>p,TS:()=>r,Tf:()=>_,V6:()=>n,Vm:()=>g,ay:()=>l,c1:()=>y,c4:()=>a,j5:()=>h,lT:()=>u,oW:()=>c});const i={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 n(e){return!!i[e]||!!i[e.toLowerCase()]}function r(e){return i[e]??i[e.toLowerCase()]}function a(e){return[...r(e)]}function o(e,t,s){s<0&&++s,s>1&&--s;const i=6*s;return i<1?e+(t-e)*i:2*s<1?t:3*s<2?e+(t-e)*(2/3-s)*6:e}function l(e,t,s,i=1){const n=(e%360+360)%360/360,r=s<=.5?s*(t+1):s+t-s*t,a=2*s-r;return[Math.round(255*o(a,r,n+1/3)),Math.round(255*o(a,r,n)),Math.round(255*o(a,r,n-1/3)),i]}function h(e){const t=e.length>5,s=t?8:4,i=(1<<s)-1,n=t?1:17,r=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 r&&(l=a&i,a>>=s,o[3]=n*l/255),l=a&i,a>>=s,o[2]=n*l,l=a&i,a>>=s,o[1]=n*l,l=a&i,a>>=s,o[0]=n*l,o}function c(e){if("#"!==e[0]||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{const t=parseInt(e.slice(1,2),16),s=parseInt(e.slice(2,3),16),i=parseInt(e.slice(3,4),16),n=5===e.length?15:parseInt(e.slice(4),16);return[t+16*t,s+16*s,i+16*i,(n+16*n)/255]}case 7:case 9:return[parseInt(e.slice(1,3),16),parseInt(e.slice(3,5),16),parseInt(e.slice(5,7),16),(7===e.length?255:parseInt(e.slice(7),16))/255];default:return null}}function u(e){const t=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(t){const e=t[2].split(/\s*,\s*/),s=t[1];if("rgb"===s&&3===e.length||"rgba"===s&&4===e.length){const t=e[0];if("%"===t.charAt(t.length-1)){const t=e.map(e=>2.56*parseFloat(e));return 4===e.length&&(t[3]=parseFloat(e[3])),f(t)}return f(e.map(e=>parseFloat(e)))}if("hsl"===s&&3===e.length||"hsla"===s&&4===e.length)return l(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3]))}return null}function f(e){return e[0]=y(e[0]),e[1]=y(e[1]),e[2]=y(e[2]),e[3]=4===e.length?p(e[3]):1,e}function d(e){let t=n(e)?r(e):null;return t??=u(e),t??=c(e),t}function g(e){const t=d(e);return null!=t?[t[0]/255,t[1]/255,t[2]/255,t[3]]:null}function p(e){return x(e,0,1)}function y(e){return Math.round(x(e,0,255))}function x(e,t,s){return e=Number(e),isNaN(e)?s:e<t?t:e>s?s:e}const _=2.2},51624:(e,t,s)=>{s.d(t,{A:()=>u});var i,n,r=s(44208),a=s(69397),o=s(93687);(n=i||(i={}))[n.varint=0]="varint",n[n.fixed64=1]="fixed64",n[n.delimited=2]="delimited",n[n.fixed32=5]="fixed32",n[n.unknown=99]="unknown";const l=4294967296,h=new TextDecoder("utf-8"),c=(0,r.A)("safari")||(0,r.A)("ios")?6:(0,r.A)("ff")?12:32;class u{constructor(e,t,s=0,n=(e?e.byteLength:0)){this._tag=0,this._dataType=i.unknown,this._init(e,t,s,n)}_init(e,t,s,i){this._data=e,this._dataView=t,this._pos=s,this._end=i}get usedMemory(){return 64+(0,a.Qf)(this._data)}asUnsafe(){return this}clone(){return new u(this._data,this._dataView,this._pos,this._end)}pos(){return this._pos}move(e){this._pos=e}nextTag(e){for(;;){if(this._pos===this._end)return!1;const t=this._decodeVarint();if(this._tag=t>>3,this._dataType=7&t,!e||e===this._tag)break;this.skip()}return!0}next(){if(this._pos===this._end)return!1;const e=this._decodeVarint();return this._tag=e>>3,this._dataType=7&e,!0}empty(){return this._pos>=this._end}tag(){return this._tag}getInt32(){return this._decodeVarint()}getInt64(){return this._decodeVarint()}getUInt32(){let e=4294967295;if(e=(127&this._data[this._pos])>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<7)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<14)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(127&this._data[this._pos])<<21)>>>0,this._data[this._pos++]<128)return e;if(e=(e|(15&this._data[this._pos])<<28)>>>0,this._data[this._pos++]<128)return e;throw new Error("Varint overflow")}getUInt64(){return this._decodeVarint()}getSInt32(){const e=this.getUInt32();return e>>>1^-(1&e)}getSInt64(){return this._decodeSVarint()}getBool(){const e=0!==this._data[this._pos];return this._skip(1),e}getEnum(){return this._decodeVarint()}getFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getUint32(t+4,!0)*l;return this._skip(8),s}getSFixed64(){const e=this._dataView,t=this._pos,s=e.getUint32(t,!0)+e.getInt32(t+4,!0)*l;return this._skip(8),s}getDouble(){const e=this._dataView.getFloat64(this._pos,!0);return this._skip(8),e}getFixed32(){const e=this._dataView.getUint32(this._pos,!0);return this._skip(4),e}getSFixed32(){const e=this._dataView.getInt32(this._pos,!0);return this._skip(4),e}getFloat(){const e=this._dataView.getFloat32(this._pos,!0);return this._skip(4),e}getString(){const e=this._getLength(),t=this._pos,s=this._toString(this._data,t,t+e);return this._skip(e),s}getBytes(){const e=this._getLength(),t=this._pos,s=this._toBytes(this._data,t,t+e);return this._skip(e),s}getLength(){return this._getLengthUnsafe()}processMessageWithArgs(e,t,s,i){const n=this.getMessage(),r=e(n,t,s,i);return n.release(),r}processMessage(e){const t=this.getMessage(),s=e(t);return t.release(),s}getMessage(){const e=this._getLength(),t=u.pool.acquire();return t._init(this._data,this._dataView,this._pos,this._pos+e),this._skip(e),t}release(){u.pool.release(this)}dataType(){return this._dataType}skip(){switch(this._dataType){case i.varint:this._decodeVarint();break;case i.fixed64:this._skip(8);break;case i.delimited:this._skip(this._getLength());break;case i.fixed32:this._skip(4);break;default:throw new Error("Invalid data type!")}}skipLen(e){this._skip(e)}_skip(e){if(this._pos+e>this._end)throw new Error("Attempt to skip past the end of buffer!");this._pos+=e}_decodeVarint(){const e=this._data;let t=this._pos,s=0,i=0;if(this._end-t>=10)do{if(i=e[t++],s|=127&i,!(128&i))break;if(i=e[t++],s|=(127&i)<<7,!(128&i))break;if(i=e[t++],s|=(127&i)<<14,!(128&i))break;if(i=e[t++],s|=(127&i)<<21,!(128&i))break;if(i=e[t++],s+=268435456*(127&i),!(128&i))break;if(i=e[t++],s+=34359738368*(127&i),!(128&i))break;if(i=e[t++],s+=4398046511104*(127&i),!(128&i))break;if(i=e[t++],s+=562949953421312*(127&i),!(128&i))break;if(i=e[t++],s+=72057594037927940*(127&i),!(128&i))break;if(i=e[t++],s+=0x8000000000000000*(127&i),!(128&i))break;throw new Error("Varint too long!")}while(0);else{let n=1;for(;t!==this._end&&(i=e[t],128&i);)++t,s+=(127&i)*n,n*=128;if(t===this._end)throw new Error("Varint overrun!");++t,s+=i*n}return this._pos=t,s}_decodeSVarint(){const e=this._data;let t,s=0,i=0;const n=1&e[this._pos];if(i=e[this._pos++],s|=127&i,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<7,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<14,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s|=(127&i)<<21,!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=268435456*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=34359738368*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(i=e[this._pos++],s+=4398046511104*(127&i),!(128&i))return n?-(s+1)/2:s/2;if(t=BigInt(s),i=e[this._pos++],t+=0x2000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);if(i=e[this._pos++],t+=0x100000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);if(i=e[this._pos++],t+=0x8000000000000000n*BigInt(127&i),!(128&i))return Number(n?-(t+1n)/2n:t/2n);throw new Error("Varint too long!")}_getLength(){if(this._dataType!==i.delimited)throw new Error("Not a delimited data type!");return this._decodeVarint()}_getLengthUnsafe(){return this.getUInt32()}_toString(e,t,s){if((s=Math.min(this._end,s))-t>c){const i=e.subarray(t,s);return h.decode(i)}let i="",n="";for(let r=t;r<s;++r){const t=e[r];128&t?n+="%"+t.toString(16):(i+=decodeURIComponent(n)+String.fromCharCode(t),n="")}return n.length&&(i+=decodeURIComponent(n)),i}_toBytes(e,t,s){return s=Math.min(this._end,s),new Uint8Array(e.buffer,t,s-t)}static{this.pool=new o.A(u,void 0,e=>{e._data=null,e._dataView=null})}}},87317:(e,t,s)=>{s.d(t,{a:()=>m,b:()=>g,c:()=>n,d:()=>c,e:()=>I,f:()=>f,g:()=>a,h:()=>y,j:()=>d,l:()=>x,n:()=>p,s:()=>r,t:()=>_});var i=s(34304);function n(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function r(e,t,s,i,n){return e[0]=t,e[1]=s,e[2]=i,e[3]=n,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],i=t[1]-e[1],n=t[2]-e[2],r=t[3]-e[3];return Math.sqrt(s*s+i*i+n*n+r*r)}function f(e,t){const s=t[0]-e[0],i=t[1]-e[1],n=t[2]-e[2],r=t[3]-e[3];return s*s+i*i+n*n+r*r}function d(e){const t=e[0],s=e[1],i=e[2],n=e[3];return Math.sqrt(t*t+s*s+i*i+n*n)}function g(e){const t=e[0],s=e[1],i=e[2],n=e[3];return t*t+s*s+i*i+n*n}function p(e,t){const s=t[0],i=t[1],n=t[2],r=t[3];let a=s*s+i*i+n*n+r*r;return a>0&&(a=1/Math.sqrt(a),e[0]=s*a,e[1]=i*a,e[2]=n*a,e[3]=r*a),e}function y(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function x(e,t,s,i){const n=t[0],r=t[1],a=t[2],o=t[3];return e[0]=n+i*(s[0]-n),e[1]=r+i*(s[1]-r),e[2]=a+i*(s[2]-a),e[3]=o+i*(s[3]-o),e}function _(e,t,s){const i=t[0],n=t[1],r=t[2],a=t[3];return e[0]=s[0]*i+s[4]*n+s[8]*r+s[12]*a,e[1]=s[1]*i+s[5]*n+s[9]*r+s[13]*a,e[2]=s[2]*i+s[6]*n+s[10]*r+s[14]*a,e[3]=s[3]*i+s[7]*n+s[11]*r+s[15]*a,e}function m(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],n=e[1],r=e[2],a=e[3],o=t[0],l=t[1],h=t[2],c=t[3],u=(0,i.FD)();return Math.abs(s-o)<=u*Math.max(1,Math.abs(s),Math.abs(o))&&Math.abs(n-l)<=u*Math.max(1,Math.abs(n),Math.abs(l))&&Math.abs(r-h)<=u*Math.max(1,Math.abs(r),Math.abs(h))&&Math.abs(a-c)<=u*Math.max(1,Math.abs(a),Math.abs(c))}const b=o,M=l,w=h,k=u,T=f,A=d,P=g;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:n,copyVec3:function(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},dist:k,distance:u,div:w,divide:h,dot:y,equals:I,exactEquals:m,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:x,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:p,random:function(e,t=1){const s=i.Ov;let n,r,a,o,l,h;do{n=2*s()-1,r=2*s()-1,l=n*n+r*r}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*n,e[1]=t*r,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,i){return e[0]=t[0]+s[0]*i,e[1]=t[1]+s[1]*i,e[2]=t[2]+s[2]*i,e[3]=t[3]+s[3]*i,e},set:r,sqrDist:T,sqrLen:P,squaredDistance:f,squaredLength:g,str:function(e){return"vec4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")"},sub:b,subtract:o,transformMat4:_,transformQuat:function(e,t,s){const i=t[0],n=t[1],r=t[2],a=s[0],o=s[1],l=s[2],h=s[3],c=h*i+o*r-l*n,u=h*n+l*i-a*r,f=h*r+a*n-o*i,d=-a*i-o*n-l*r;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"}))},91829:(e,t,s)=>{function i(){return[0,0,0,0]}function n(e){return[e[0],e[1],e[2],e[3]]}function r(e,t,s,i){return[e,t,s,i]}function a(e,t,s,i){return[e,t,s,i]}function o(e,t=[0,0,0,0]){const s=Math.min(4,e.length);for(let i=0;i<s;++i)t[i]=e[i];return t}function l(){return r(1,1,1,1)}function h(){return r(1,0,0,0)}function c(){return r(0,1,0,0)}function u(){return r(0,0,1,0)}function f(){return r(0,0,0,1)}s.d(t,{CN:()=>a,Un:()=>g,ci:()=>o,fA:()=>r,o8:()=>n,uY:()=>d,vt:()=>i});const d=[0,0,0,0],g=l(),p=h(),y=c(),x=u(),_=f();Object.freeze(Object.defineProperty({__proto__:null,ONES:g,UNIT_W:_,UNIT_X:p,UNIT_Y:y,UNIT_Z:x,ZEROS:d,clone:n,create:i,freeze:a,fromArray:o,fromValues:r,ones:l,unitW:f,unitX:h,unitY:c,unitZ:u,zeros:function(){return[0,0,0,0]}},Symbol.toStringTag,{value:"Module"}))}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[2944],{24151:(t,n,e)=>{var a;e.d(n,{RT:()=>a}),function(t){t[t.Global=1]="Global",t[t.Local=2]="Local"}(a||(a={}))},27921:(t,n,e)=>{e.d(n,{$Q:()=>R,C:()=>h,Cr:()=>d,LV:()=>c,Nj:()=>L,O_:()=>l,Qj:()=>u,T7:()=>O,Tj:()=>P,Ui:()=>m,_I:()=>C,fA:()=>f,gv:()=>g,lU:()=>I,mN:()=>b,mP:()=>A,mR:()=>S,v1:()=>z,vE:()=>D,vt:()=>o});var a=e(34727),r=e(38954),i=e(51850),s=(e(87317),e(44280),e(32114));function o(t=F){return[t[0],t[1],t[2],t[3]]}function c(t=F[0],n=F[1],e=F[2],a=F[3]){return f(t,n,e,a,s.Km.get())}function h(t,n){return f(n[0],n[1],n[2],n[3],t)}function u(t){return t}function f(t,n,e,a,r=o()){return r[0]=t,r[1]=n,r[2]=e,r[3]=a,r}function l(t,n,e){const a=n[0]*n[0]+n[1]*n[1]+n[2]*n[2],r=Math.abs(a-1)>1e-5&&a>1e-12?1/Math.sqrt(a):1;return e[0]=n[0]*r,e[1]=n[1]*r,e[2]=n[2]*r,e[3]=-(e[0]*t[0]+e[1]*t[1]+e[2]*t[2]),e}function d(t,n,e,a=o()){const r=e[0]-n[0],i=e[1]-n[1],s=e[2]-n[2],c=t[0]-n[0],h=t[1]-n[1],u=t[2]-n[2],f=i*u-s*h,l=s*c-r*u,d=r*h-i*c,I=f*f+l*l+d*d,E=Math.abs(I-1)>1e-5&&I>1e-12?1/Math.sqrt(I):1;return a[0]=f*E,a[1]=l*E,a[2]=d*E,a[3]=-(a[0]*t[0]+a[1]*t[1]+a[2]*t[2]),a}function I(t,n,e,a=0,i=Math.floor(e*(1/3)),s=Math.floor(e*(2/3))){if(e<3)return!1;n(M,a);let o=i,c=!1;for(;o<e-1&&!c;)n(_,o),o++,c=!(0,r.q)(M,_);if(!c)return!1;for(o=Math.max(o,s),c=!1;o<e&&!c;)n(N,o),o++,(0,r.d)(T,M,_),(0,r.n)(T,T),(0,r.d)(v,_,N),(0,r.n)(v,v),c=!(0,r.q)(M,N)&&!(0,r.q)(_,N)&&Math.abs((0,r.e)(T,v))<E;return c?(d(M,_,N,t),!0):(0!==a||1!==i||2!==s)&&I(t,n,e,0,1,2)}e(32728);const E=.99619469809,M=(0,i.vt)(),_=(0,i.vt)(),N=(0,i.vt)(),T=(0,i.vt)(),v=(0,i.vt)();function A(t,n,e){return n!==t&&h(t,n),t[3]=-(0,r.e)(t,e),t}function S(t,n,e,a){return(0,r.h)(N,n,t),l(e,N,a)}function m(t,n,e){return null!=n&&p(D(t,n.origin,n.direction,x,e))}function O(t,n,e){return p(D(t,n.origin,n.vector,z.NONE,e))}function g(t,n,e){return p(D(t,n.origin,n.vector,z.CLAMP,e))}function P(t,n){return b(t,n)>=0}function R(t,n){const e=(0,r.e)(t,n.ray.direction),a=-b(t,n.ray.origin);if(a<0&&e>=0)return!1;if(e>-1e-6&&e<1e-6)return a>0;if((a<0||e<0)&&!(a<0&&e<0))return!0;const i=a/e;return e>0?i<n.c1&&(n.c1=i):i>n.c0&&(n.c0=i),n.c0<=n.c1}function C(t,n,e){const a=(0,r.g)(s.rq.get(),t,-t[3]),i=function(t,n,e){const a=(0,r.g)(s.rq.get(),t,(0,r.e)(t,n));return(0,r.d)(e,n,a),e}(t,(0,r.d)(s.rq.get(),n,a),s.rq.get());return(0,r.f)(e,i,a),e}function b(t,n){return(0,r.e)(t,n)+t[3]}var L,j;function p(t){return t===L.INTERSECTS_INSIDE_OUT||t===L.INTERSECTS_OUTSIDE_IN}function D(t,n,e,i,s){const o=(0,r.e)(t,e),c=b(t,n);if(0===o)return c>=0?L.INSIDE:L.OUTSIDE;let h=-c/o;return i&z.CLAMP&&(h=(0,a.qE)(h,0,1)),!(i&z.INFINITE_MIN)&&h<0||!(i&z.INFINITE_MAX)&&h>1?c>=0?L.INSIDE:L.OUTSIDE:((0,r.f)(s,n,(0,r.g)(s,e,h)),c>=0?L.INTERSECTS_INSIDE_OUT:L.INTERSECTS_OUTSIDE_IN)}(j=L||(L={}))[j.INTERSECTS_INSIDE_OUT=0]="INTERSECTS_INSIDE_OUT",j[j.INTERSECTS_OUTSIDE_IN=1]="INTERSECTS_OUTSIDE_IN",j[j.INSIDE=2]="INSIDE",j[j.OUTSIDE=3]="OUTSIDE";const F=[0,0,1,0];var z;!function(t){t[t.NONE=0]="NONE",t[t.CLAMP=1]="CLAMP",t[t.INFINITE_MIN=4]="INFINITE_MIN",t[t.INFINITE_MAX=8]="INFINITE_MAX"}(z||(z={})),z.INFINITE_MIN,z.INFINITE_MAX;const x=z.INFINITE_MAX},32728:(t,n,e)=>{e.d(n,{nu:()=>i}),e(34727);var a=e(38954),r=e(51850);function i(t,n,e,i=(0,r.vt)()){const c=(0,a.l)(t),h=(0,a.l)(n),u=(0,a.e)(t,n)/(c*h);if(u<.9999999999999999){const r=Math.acos(u),f=((1-e)*c+e*h)/Math.sin(r),l=f/c*Math.sin((1-e)*r),d=f/h*Math.sin(e*r);return(0,a.g)(s,t,l),(0,a.g)(o,n,d),(0,a.f)(i,s,o)}return(0,a.m)(i,t,n,e)}(0,r.vt)(),(0,r.vt)(),(0,r.vt)();const s=(0,r.vt)(),o=(0,r.vt)()},46540:(t,n,e)=>{var a;e.d(n,{r:()=>a}),function(t){t.POSITION="position",t.NORMAL="normal",t.NORMALCOMPRESSED="normalCompressed",t.UV0="uv0",t.UVI="uvi",t.COLOR="color",t.SYMBOLCOLOR="symbolColor",t.SIZE="size",t.ROTATION="rotation",t.TANGENT="tangent",t.OFFSET="offset",t.PERSPECTIVEDIVIDE="perspectiveDivide",t.CENTEROFFSETANDDISTANCE="centerOffsetAndDistance",t.LENGTH="length",t.NEXTDELTA="nextDelta",t.PREVIOUSDELTA="previousDelta",t.U0="u0",t.LINEPARAMETERS="lineParameters",t.COLORFEATUREATTRIBUTE="colorFeatureAttribute",t.SIZEFEATUREATTRIBUTE="sizeFeatureAttribute",t.OPACITYFEATUREATTRIBUTE="opacityFeatureAttribute",t.DISTANCETOSTART="distanceToStart",t.UVMAPSPACE="uvMapSpace",t.BOUNDINGRECT="boundingRect",t.UVREGION="uvRegion",t.PROFILERIGHT="profileRight",t.PROFILEUP="profileUp",t.PROFILEVERTEXANDNORMAL="profileVertexAndNormal",t.PROFILEAUXDATA="profileAuxData",t.INSTANCEMODELORIGINHI="instanceModelOriginHi",t.INSTANCEMODELORIGINLO="instanceModelOriginLo",t.INSTANCEMODEL="instanceModel",t.INSTANCEMODELNORMAL="instanceModelNormal",t.INSTANCECOLOR="instanceColor",t.INSTANCEFEATUREATTRIBUTE="instanceFeatureAttribute",t.LOCALTRANSFORM="localTransform",t.GLOBALTRANSFORM="globalTransform",t.BOUNDINGSPHERE="boundingSphere",t.MODELORIGIN="modelOrigin",t.MODELSCALEFACTORS="modelScaleFactors",t.FEATUREATTRIBUTE="featureAttribute",t.STATE="state",t.LODLEVEL="lodLevel",t.POSITION0="position0",t.POSITION1="position1",t.NORMAL2COMPRESSED="normal2Compressed",t.COMPONENTINDEX="componentIndex",t.VARIANTOFFSET="variantOffset",t.VARIANTSTROKE="variantStroke",t.VARIANTEXTENSION="variantExtension",t.SIDENESS="sideness",t.START="start",t.END="end",t.UP="up",t.START_UP="startUp",t.END_UP="endUp",t.EXTRUDE="extrude",t.OLIDCOLOR="objectAndLayerIdColor",t.INSTANCEOBJECTANDLAYERIDCOLOR="instanceObjectAndLayerIdColor"}(a||(a={}))},46610:(t,n,e)=>{e.d(n,{K:()=>a,n:()=>r});class a{constructor(t,n,e=n){this.data=t,this.size=n,this.stride=e}}class r extends a{constructor(t,n,e,a=!1,r=e){super(t,e,r),this.indices=n,this.exclusive=a}}},48353:(t,n,e)=>{e.d(n,{l:()=>h});var a=e(34727),r=e(58083),i=e(51850);function s(t,n,e){const a=Math.sin(t),r=Math.cos(t),i=Math.sin(n),s=Math.cos(n),o=e;return o[0]=-a,o[4]=-i*r,o[8]=s*r,o[12]=0,o[1]=r,o[5]=-i*a,o[9]=s*a,o[13]=0,o[2]=0,o[6]=s,o[10]=i,o[14]=0,o[3]=0,o[7]=0,o[11]=0,o[15]=1,o}var o=e(37539),c=e(21325);function h(t,n,e,a){const i=(0,o.Tp)(t,a);if(null==i)return!1;const h=i.source.spatialReferenceId,I=i.dest.spatialReferenceId;if(h===I&&!u(I)&&(h!==o.rz.UNKNOWN||(0,c.aI)(t,a)))return(0,r.kN)(e,n),!0;if(u(I)){const t=o.w5[h][o.rz.LON_LAT],a=o.w5[o.rz.LON_LAT][I];return null!=t&&null!=a&&(t(n,0,l,0),a(l,0,d,0),s(f*l[0],f*l[1],e),e[12]=d[0],e[13]=d[1],e[14]=d[2],!0)}const E=u(h);if((I===o.rz.WEB_MERCATOR||I===o.rz.PLATE_CARREE||I===o.rz.WGS84||I===o.rz.CGCS2000)&&(h===o.rz.WGS84||E||h===o.rz.WEB_MERCATOR||h===o.rz.CGCS2000)){const t=o.w5[h][o.rz.LON_LAT],a=o.w5[o.rz.LON_LAT][I];return null!=t&&null!=a&&(t(n,0,l,0),a(l,0,d,0),E?function(t,n,e){s(t,n,e),(0,r.mg)(e,e)}(f*l[0],f*l[1],e):(0,r.D_)(e),e[12]=d[0],e[13]=d[1],e[14]=d[2],!0)}return!1}function u(t){return t===o.rz.SPHERICAL_ECEF||t===o.rz.SPHERICAL_MARS_PCPF||t===o.rz.SPHERICAL_MOON_PCPF||t===o.rz.WGS84_ECEF}const f=(0,a.kU)(1),l=(0,i.vt)(),d=(0,i.vt)()},57005:(t,n,e)=>{e.d(n,{ab:()=>vt,gm:()=>Lt});var a=e(77690),r=e(29242),i=e(9093),s=e(67026),o=e(82534),c=e(38954),h=e(51850),u=e(87317),f=e(91829),l=e(73941),d=e(98764),I=e(48353),E=e(9762),M=e(37539),_=e(27921),N=e(21325),T=e(32114),v=e(24151),A=e(48163),S=e(46610);const m=1e-6,O=(0,h.vt)(),g=(0,h.vt)();function P(t,n,e,a,r,i,s,o,c,h){return function(t,n,e){let a=Nt(t.maxVert[0],t.minVert[0]),r=0;for(let n=1;n<7;++n){const e=Nt(t.maxVert[n],t.minVert[n]);e>a&&(a=e,r=n)}It(n,t.minVert[r]),It(e,t.maxVert[r])}(t,a,r),Nt(a,r)<m?1:(lt(s,a,r),Mt(s,s),function(t,n,e,a){const{data:r,size:i}=t;let s=Number.NEGATIVE_INFINITY,o=0;for(let t=0;t<r.length;t+=i){x[0]=r[t]-n[0],x[1]=r[t+1]-n[1],x[2]=r[t+2]-n[2];const a=e[0]*x[0]+e[1]*x[1]+e[2]*x[2],i=e[0]*e[0]+e[1]*e[1]+e[2]*e[2],c=x[0]*x[0]+x[1]*x[1]+x[2]*x[2]-a*a/i;c>s&&(s=c,o=t)}return It(a,r,o),s}(n,a,s,i)<m?2:(lt(o,r,i),Mt(o,o),lt(c,i,a),Mt(c,c),Et(e,o,s),Mt(e,e),B(n,e,s,o,c,h),0))}const R=(0,h.vt)(),C=(0,h.vt)(),b=(0,h.vt)(),L=(0,h.vt)(),j=(0,h.vt)(),p=(0,h.vt)(),D=(0,h.vt)(),F=(0,h.vt)();function z(t,n,e,a,r,i,s,o,c){(function(t,n,e,a,r){!function(t,n,e,a,r){const{data:i,size:s}=t;It(a,i),It(r,a),e[0]=Tt(H,n),e[1]=e[0];for(let t=s;t<i.length;t+=s){const s=i[t]*n[0]+i[t+1]*n[1]+i[t+2]*n[2];s<e[0]&&(e[0]=s,It(a,i,t)),s>e[1]&&(e[1]=s,It(r,i,t))}}(t,n,U,r,a);const i=Tt(e,n);U[1]-m<=i&&(a[0]=void 0),U[0]+m>=i&&(r[0]=void 0)})(t,n,e,R,C),void 0!==R[0]&&(lt(b,R,e),Mt(b,b),lt(L,R,a),Mt(L,L),lt(j,R,r),Mt(j,j),Et(p,L,i),Mt(p,p),Et(D,j,s),Mt(D,D),Et(F,b,o),Mt(F,F),B(t,p,i,L,b,c),B(t,D,s,j,L,c),B(t,F,o,b,j,c)),void 0!==C[0]&&(lt(b,C,e),Mt(b,b),lt(L,C,a),Mt(L,L),lt(j,C,r),Mt(j,j),Et(p,L,i),Mt(p,p),Et(D,j,s),Mt(D,D),Et(F,b,o),Mt(F,F),B(t,p,i,L,b,c),B(t,D,s,j,L,c),B(t,F,o,b,j,c))}const x=[0,0,0],U=(0,A.vt)(),w=(0,h.vt)(),q=(0,h.vt)(),y=(0,h.vt)(),V=(0,h.vt)(),G=(0,h.vt)(),X=(0,h.vt)();function B(t,n,e,a,r,i){if(_t(n)<m)return;Et(w,e,n),Et(q,a,n),Et(y,r,n),Q(t,n,U),G[1]=U[0],V[1]=U[1],X[1]=V[1]-G[1];const s=[e,a,r],o=[w,q,y];for(let e=0;e<3;++e){Q(t,s[e],U),G[0]=U[0],V[0]=U[1],Q(t,o[e],U),G[2]=U[0],V[2]=U[1],X[0]=V[0]-G[0],X[2]=V[2]-G[2];const a=ut(X);a<i.quality&&(It(i.b0,s[e]),It(i.b1,n),It(i.b2,o[e]),i.quality=a)}}const H=(0,h.vt)();function Q(t,n,e){const{data:a,size:r}=t;e[0]=Number.POSITIVE_INFINITY,e[1]=Number.NEGATIVE_INFINITY;for(let t=0;t<a.length;t+=r){const r=a[t]*n[0]+a[t+1]*n[1]+a[t+2]*n[2];e[0]=Math.min(e[0],r),e[1]=Math.max(e[1],r)}}function Y(t,n,e){e.center=t,e.halfSize=(0,c.g)(n,n,.5),e.quaternion=o.zK}const k=(0,h.vt)(),W=(0,h.vt)(),Z=(0,h.vt)(),K=(0,h.vt)(),J=(0,h.vt)(),$=(0,h.vt)();function tt(t,n,e){It(k,n),Math.abs(n[0])>Math.abs(n[1])&&Math.abs(n[0])>Math.abs(n[2])?k[0]=0:Math.abs(n[1])>Math.abs(n[2])?k[1]=0:k[2]=0,_t(k)<m&&(k[0]=k[1]=k[2]=1),Et(W,n,k),Mt(W,W),Et(Z,n,W),Mt(Z,Z),nt(t,n,W,Z,K,J),lt($,J,K),ot(n,W,Z,K,J,$,e)}function nt(t,n,e,a,r,i){Q(t,n,U),r[0]=U[0],i[0]=U[1],Q(t,e,U),r[1]=U[0],i[1]=U[1],Q(t,a,U),r[2]=U[0],i[2]=U[1]}const et=(0,h.vt)(),at=(0,h.vt)(),rt=(0,h.vt)(),it=(0,r.fA)(1,0,0,0,1,0,0,0,1),st=(0,o.vt)();function ot(t,n,e,a,r,i,s){it[0]=t[0],it[1]=t[1],it[2]=t[2],it[3]=n[0],it[4]=n[1],it[5]=n[2],it[6]=e[0],it[7]=e[1],it[8]=e[2],s.quaternion=function(t,n){const e=n[0]+n[4]+n[8];if(e>0){let a=Math.sqrt(e+1);t[3]=.5*a,a=.5/a,t[0]=(n[5]-n[7])*a,t[1]=(n[6]-n[2])*a,t[2]=(n[1]-n[3])*a}else{let e=0;n[4]>n[0]&&(e=1),n[8]>n[3*e+e]&&(e=2);const a=(e+1)%3,r=(e+2)%3;let i=Math.sqrt(n[3*e+e]-n[3*a+a]-n[3*r+r]+1);t[e]=.5*i,i=.5/i,t[3]=(n[3*a+r]-n[3*r+a])*i,t[a]=(n[3*a+e]+n[3*e+a])*i,t[r]=(n[3*r+e]+n[3*e+r])*i}return t}(st,it),ft(et,a,r),dt(et,et,.5),dt(at,t,et[0]),dt(rt,n,et[1]),ft(at,at,rt),dt(rt,e,et[2]),s.center=(0,c.f)(at,at,rt),s.halfSize=(0,c.g)(et,i,.5)}class ct{constructor(t){this.minVert=new Array(7),this.maxVert=new Array(7),this.buffer=new ArrayBuffer(448);let n=0;this.minProj=new Float64Array(this.buffer,n,7),n+=56,this.maxProj=new Float64Array(this.buffer,n,7),n+=56;for(let t=0;t<7;++t)this.minVert[t]=new Float64Array(this.buffer,n,3),n+=24;for(let t=0;t<7;++t)this.maxVert[t]=new Float64Array(this.buffer,n,3),n+=24;for(let t=0;t<7;++t)this.minProj[t]=Number.POSITIVE_INFINITY,this.maxProj[t]=Number.NEGATIVE_INFINITY;const e=new Array(7),a=new Array(7),{data:r,size:i}=t;for(let t=0;t<r.length;t+=i){let n=r[t];n<this.minProj[0]&&(this.minProj[0]=n,e[0]=t),n>this.maxProj[0]&&(this.maxProj[0]=n,a[0]=t),n=r[t+1],n<this.minProj[1]&&(this.minProj[1]=n,e[1]=t),n>this.maxProj[1]&&(this.maxProj[1]=n,a[1]=t),n=r[t+2],n<this.minProj[2]&&(this.minProj[2]=n,e[2]=t),n>this.maxProj[2]&&(this.maxProj[2]=n,a[2]=t),n=r[t]+r[t+1]+r[t+2],n<this.minProj[3]&&(this.minProj[3]=n,e[3]=t),n>this.maxProj[3]&&(this.maxProj[3]=n,a[3]=t),n=r[t]+r[t+1]-r[t+2],n<this.minProj[4]&&(this.minProj[4]=n,e[4]=t),n>this.maxProj[4]&&(this.maxProj[4]=n,a[4]=t),n=r[t]-r[t+1]+r[t+2],n<this.minProj[5]&&(this.minProj[5]=n,e[5]=t),n>this.maxProj[5]&&(this.maxProj[5]=n,a[5]=t),n=r[t]-r[t+1]-r[t+2],n<this.minProj[6]&&(this.minProj[6]=n,e[6]=t),n>this.maxProj[6]&&(this.maxProj[6]=n,a[6]=t)}for(let t=0;t<7;++t){let n=e[t];It(this.minVert[t],r,n),n=a[t],It(this.maxVert[t],r,n)}}}class ht{constructor(){this.b0=(0,h.fA)(1,0,0),this.b1=(0,h.fA)(0,1,0),this.b2=(0,h.fA)(0,0,1),this.quality=0}}function ut(t){return t[0]*t[1]+t[0]*t[2]+t[1]*t[2]}function ft(t,n,e){t[0]=n[0]+e[0],t[1]=n[1]+e[1],t[2]=n[2]+e[2]}function lt(t,n,e){t[0]=n[0]-e[0],t[1]=n[1]-e[1],t[2]=n[2]-e[2]}function dt(t,n,e){t[0]=n[0]*e,t[1]=n[1]*e,t[2]=n[2]*e}function It(t,n,e=0){t[0]=n[e],t[1]=n[e+1],t[2]=n[e+2]}function Et(t,n,e){const a=n[0],r=n[1],i=n[2],s=e[0],o=e[1],c=e[2];t[0]=r*c-i*o,t[1]=i*s-a*c,t[2]=a*o-r*s}function Mt(t,n){const e=n[0]*n[0]+n[1]*n[1]+n[2]*n[2];if(e>0){const a=1/Math.sqrt(e);t[0]=n[0]*a,t[1]=n[1]*a,t[2]=n[2]*a}}function _t(t){return t[0]*t[0]+t[1]*t[1]+t[2]*t[2]}function Nt(t,n){const e=n[0]-t[0],a=n[1]-t[1],r=n[2]-t[2];return e*e+a*a+r*r}function Tt(t,n){return t[0]*n[0]+t[1]*n[1]+t[2]*n[2]}class vt{constructor(t=h.uY,n=Bt,e=o.zK){this._data=[t[0],t[1],t[2],n[0],n[1],n[2],e[0],e[1],e[2],e[3]]}clone(){const t=new vt;return t._data=this._data.slice(),t}invalidate(){this._data[3]=-1}get isValid(){return this._data[3]>=0}static fromData(t){const n=new vt;return n._data=t.slice(),n}static fromJSON(t){return new vt(t.center,t.halfSize,t.quaternion)}copy(t){this._data=t.data.slice()}get center(){return(0,c.i)(T.rq.get(),this._data[0],this._data[1],this._data[2])}get centerX(){return this._data[0]}get centerY(){return this._data[1]}get centerZ(){return this._data[2]}getCenter(t){return t[0]=this._data[0],t[1]=this._data[1],t[2]=this._data[2],t}set center(t){this._data[0]=t[0],this._data[1]=t[1],this._data[2]=t[2]}setCenter(t,n,e){this._data[0]=t,this._data[1]=n,this._data[2]=e}get halfSize(){return(0,c.i)(T.rq.get(),this._data[3],this._data[4],this._data[5])}get halfSizeX(){return this._data[3]}get halfSizeY(){return this._data[4]}get halfSizeZ(){return this._data[5]}getHalfSize(t){return t[0]=this._data[3],t[1]=this._data[4],t[2]=this._data[5],t}set halfSize(t){this._data[3]=t[0],this._data[4]=t[1],this._data[5]=t[2]}get quaternion(){return(0,s.hZ)(T.J8.get(),this._data[6],this._data[7],this._data[8],this._data[9])}getQuaternion(t){return t[0]=this._data[6],t[1]=this._data[7],t[2]=this._data[8],t[3]=this._data[9],t}set quaternion(t){this._data[6]=t[0],this._data[7]=t[1],this._data[8]=t[2],this._data[9]=t[3]}get data(){return this._data}getCorners(t){const n=At,e=this._data;n[0]=e[6],n[1]=e[7],n[2]=e[8],n[3]=e[9];for(let a=0;a<8;++a){const r=t[a];r[0]=(1&a?-1:1)*e[3],r[1]=(2&a?-1:1)*e[4],r[2]=(4&a?-1:1)*e[5],(0,c.v)(r,r,n),r[0]+=e[0],r[1]+=e[1],r[2]+=e[2]}}doesIntersectFrustumConservativeApproximation(t){return this.intersectPlane(t[0])<=0&&this.intersectPlane(t[1])<=0&&this.intersectPlane(t[2])<=0&&this.intersectPlane(t[3])<=0&&this.intersectPlane(t[4])<=0&&this.intersectPlane(t[5])<=0}get radius(){const t=this._data[3],n=this._data[4],e=this._data[5];return Math.sqrt(t*t+n*n+e*e)}intersectSphere(t){Ot[0]=this._data[0]-t[0],Ot[1]=this._data[1]-t[1],Ot[2]=this._data[2]-t[2];const n=this.getQuaternion(St);return(0,s.Xr)(At,n),(0,c.v)(Ot,Ot,At),(0,c.w)(Ot,Ot),gt[0]=Math.min(Ot[0],this._data[3]),gt[1]=Math.min(Ot[1],this._data[4]),gt[2]=Math.min(Ot[2],this._data[5]),(0,c.x)(gt,Ot)<t[3]*t[3]}intersectSphereWithMBS(t,n=this.radius){const e=this._data;Ot[0]=e[0]-t[0],Ot[1]=e[1]-t[1],Ot[2]=e[2]-t[2];const a=t[3],r=a+n;return!((0,c.y)(Ot)>r*r)&&(At[0]=-e[6],At[1]=-e[7],At[2]=-e[8],At[3]=e[9],(0,c.v)(Ot,Ot,At),(0,c.w)(Ot,Ot),gt[0]=Math.min(Ot[0],e[3]),gt[1]=Math.min(Ot[1],e[4]),gt[2]=Math.min(Ot[2],e[5]),(0,c.x)(gt,Ot)<a*a)}intersectPlane(t){const n=t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3],e=this.projectedRadius((0,_.Qj)(t));return n>e?1:n<-e?-1:0}intersectRay(t,n,e=0){const a=this._data,r=At;r[0]=-a[6],r[1]=-a[7],r[2]=-a[8],r[3]=a[9],Ot[0]=t[0]-a[0],Ot[1]=t[1]-a[1],Ot[2]=t[2]-a[2];const i=(0,c.v)(Ot,Ot,At),s=(0,c.v)(gt,n,At);let o=-1/0,h=1/0;const u=this.getHalfSize(Ut);for(let t=0;t<3;t++){const n=i[t],a=s[t],r=u[t]+e;if(Math.abs(a)>1e-6){const t=(r-n)/a,e=(-r-n)/a;o=Math.max(o,Math.min(t,e)),h=Math.min(h,Math.max(t,e))}else if(n>r||n<-r)return!1}return o<=h}projectedArea(t,n,e,r){const i=this.getQuaternion(St);(0,s.Xr)(At,i),Ot[0]=t[0]-this._data[0],Ot[1]=t[1]-this._data[1],Ot[2]=t[2]-this._data[2],(0,c.v)(Ot,Ot,At);const o=this.getHalfSize(Ut),h=Ot[0]<-o[0]?-1:Ot[0]>o[0]?1:0,f=Ot[1]<-o[1]?-1:Ot[1]>o[1]?1:0,l=Ot[2]<-o[2]?-1:Ot[2]>o[2]?1:0,d=Math.abs(h)+Math.abs(f)+Math.abs(l);if(0===d)return 1/0;const I=1===d?4:6,E=6*(h+3*f+9*l+13);(0,a.I0)(wt,i),(0,a.hs)(wt,wt,o);const M=this.getCenter(zt);for(let t=0;t<I;t++){const e=bt[E+t];(0,c.i)(Ot,((1&e)<<1)-1,(2&e)-1,((4&e)>>1)-1),(0,c.o)(Ot,Ot,wt),(0,c.f)(Pt,M,Ot),Pt[3]=1,(0,u.t)(Pt,Pt,n);const a=1/Math.max(1e-6,Pt[3]);Ct[2*t]=Pt[0]*a,Ct[2*t+1]=Pt[1]*a}const _=2*I-2;let N=Ct[0]*(Ct[3]-Ct[_+1])+Ct[_]*(Ct[1]-Ct[_-1]);for(let t=2;t<_;t+=2)N+=Ct[t]*(Ct[t+3]-Ct[t-1]);return Math.abs(N)*e*r*.125}projectedRadius(t){const n=this.getQuaternion(St);return(0,s.Xr)(At,n),(0,c.v)(Ot,t,At),Math.abs(Ot[0]*this._data[3])+Math.abs(Ot[1]*this._data[4])+Math.abs(Ot[2]*this._data[5])}minimumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]-this.projectedRadius((0,_.Qj)(t))}maximumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]+this.projectedRadius((0,_.Qj)(t))}toAaBoundingBox(t){const n=this.getQuaternion(St),e=(0,a.I0)(wt,n),r=this._data[3]*Math.abs(e[0])+this._data[4]*Math.abs(e[3])+this._data[5]*Math.abs(e[6]),i=this._data[3]*Math.abs(e[1])+this._data[4]*Math.abs(e[4])+this._data[5]*Math.abs(e[7]),s=this._data[3]*Math.abs(e[2])+this._data[4]*Math.abs(e[5])+this._data[5]*Math.abs(e[8]);t[0]=this._data[0]-r,t[1]=this._data[1]-i,t[2]=this._data[2]-s,t[3]=this._data[0]+r,t[4]=this._data[1]+i,t[5]=this._data[2]+s}transform(t,n,e,a=0,r=(0,d.lO)(e),i=(0,d.lO)(n),o=(0,M.jd)(n,i)){if(e===r)n.isGeographic?function(t,n,e,a,r=(0,d.lO)(e)){const i=(0,l.tO)(e),o=1+Math.max(0,a)/(i.radius+t.centerZ);t.getCenter(Ft),Ft[2]+=a,(0,E.projectBuffer)(Ft,e,0,Ft,r,0),n.center=Ft;const h=t.getQuaternion(St);n.quaternion=h,(0,s.Xr)(At,h),(0,c.i)(Vt,0,0,1),(0,c.v)(Vt,Vt,At);const u=t.getHalfSize(Ut);(0,c.i)(Vt,u[0]*Math.abs(Vt[0]),u[1]*Math.abs(Vt[1]),u[2]*Math.abs(Vt[2])),(0,c.g)(Vt,Vt,i.inverseFlattening),(0,c.f)(Vt,u,Vt),n.halfSize=(0,c.g)(Vt,Vt,o)}(this,t,n,a,i):function(t,n,e,a,r=(0,d.lO)(e),i=(0,M.jd)(e,r)){t.getCorners(yt),t.getCenter(Ft),Ft[2]+=a,(0,I.l)(e,Ft,qt,r),n.setCenter(qt[12],qt[13],qt[14]);const o=2*Math.sqrt(1+qt[0]+qt[5]+qt[10]);At[0]=(qt[6]-qt[9])/o,At[1]=(qt[8]-qt[2])/o,At[2]=(qt[1]-qt[4])/o,At[3]=.25*o;const h=t.getQuaternion(St);n.quaternion=(0,s.lw)(At,At,h),(0,s.Xr)(At,At),(0,c.i)(Gt,0,0,0);const u=n.getCenter(xt);for(const t of yt)t[2]+=a,i(t,0,t,0),(0,c.a)(Vt,t,u),(0,c.v)(Vt,Vt,At),(0,c.w)(Vt,Vt),(0,c.z)(Gt,Gt,Vt);n.halfSize=Gt}(this,t,n,a,i,o);else if(n.isWGS84&&(e.isWebMercator||(0,N.r1)(e)))!function(t,n,e,a,r){n.getCenter(zt),zt[2]+=r;const i=(0,d.lO)(e);(0,E.projectBuffer)(zt,t,0,zt,i,0),jt(i,n,zt,e,a)}(n,this,e,t,a);else if(n.isWebMercator&&(0,N.r1)(e))!function(t,n,e,a,r){n.getCenter(zt),zt[2]+=r,jt(t,n,zt,e,a)}(n,this,e,t,a);else{const r=this.getCenter(zt);r[2]+=a,(0,E.projectBuffer)(r,n,0,r,e,0),t.center=r,this!==t&&(t.quaternion=this.getQuaternion(St),t.halfSize=this.getHalfSize(Ut))}}}const At=(0,o.vt)(),St=(0,o.vt)(),mt=(0,o.vt)(),Ot=(0,h.vt)(),gt=(0,h.vt)(),Pt=(0,f.vt)();function Rt(t,n=new vt){return function(t,n){const{data:e,size:a}=t,r=e.length/a;if(r<=0)return;const i=new ct(t);ft(O,i.minProj,i.maxProj),dt(O,O,.5),lt(g,i.maxProj,i.minProj);const s=ut(g),o=new ht;o.quality=s,r<14&&(t=new S.K(new Float64Array(i.buffer,112,42),3));const c=(0,h.vt)(),u=(0,h.vt)(),f=(0,h.vt)(),l=(0,h.vt)(),d=(0,h.vt)(),I=(0,h.vt)(),E=(0,h.vt)();switch(P(i,t,E,c,u,f,l,d,I,o)){case 1:return void Y(O,g,n);case 2:return void tt(t,l,n)}z(t,E,c,u,f,l,d,I,o),nt(t,o.b0,o.b1,o.b2,K,J);const M=(0,h.vt)();lt(M,J,K),o.quality=ut(M),o.quality<s?ot(o.b0,o.b1,o.b2,K,J,M,n):Y(O,g,n)}(t,n),n}const Ct=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1,1.1,1.2],bt=(()=>{const t=new Int8Array(162);let n=0;const e=e=>{for(let a=0;a<e.length;a++)t[n+a]=e[a];n+=6};return e([6,2,3,1,5,4]),e([0,2,3,1,5,4]),e([0,2,3,7,5,4]),e([0,1,3,2,6,4]),e([0,1,3,2,0,0]),e([0,1,5,7,3,2]),e([0,1,3,7,6,4]),e([0,1,3,7,6,2]),e([0,1,5,7,6,2]),e([0,1,5,4,6,2]),e([0,1,5,4,0,0]),e([0,1,3,7,5,4]),e([0,2,6,4,0,0]),e([0,0,0,0,0,0]),e([1,3,7,5,0,0]),e([2,3,7,6,4,0]),e([2,3,7,6,0,0]),e([2,3,1,5,7,6]),e([0,1,5,7,6,2]),e([0,1,5,7,6,4]),e([0,1,3,7,6,4]),e([4,5,7,6,2,0]),e([4,5,7,6,0,0]),e([4,5,1,3,7,6]),e([0,2,3,7,5,4]),e([6,2,3,7,5,4]),e([6,2,3,1,5,4]),t})();function Lt(t,n,e,a,r){const i=t.getQuaternion(St);r.quaternion=i,(0,s.Xr)(At,i);const o=t.getCenter(zt),u=t.getHalfSize(Ut);if(a===v.RT.Global){(0,c.v)(Vt,o,At),(0,c.w)(Gt,Vt),(0,c.A)(Xt,Gt,u),(0,c.a)(Xt,Gt,Xt);const a=(0,c.l)(Xt);(0,c.f)(Xt,Gt,u);const i=(0,c.l)(Xt);if(a<e)r.center=o,(0,c.i)(Vt,e,e,e),r.halfSize=(0,c.f)(Vt,u,Vt);else{const s=i>0?1+n/i:1,o=a>0?1+e/a:1,h=(o+s)/2,f=(o-s)/2;(0,c.g)(Xt,Gt,f),r.halfSize=(0,c.b)(Xt,Xt,u,h),(0,c.g)(Xt,Gt,h),(0,c.b)(Xt,Xt,u,f),(0,c.B)(Vt,Vt),(0,c.C)(Vt,Xt,Vt);const l=t.getQuaternion(mt);r.center=(0,c.v)(Vt,Vt,l)}}else{r.center=(0,c.b)(Vt,o,h.Cb,(e+n)/2);const t=(0,c.v)(Vt,h.Cb,At);(0,c.w)(t,t),r.halfSize=(0,c.b)(Gt,u,t,(e-n)/2)}return r}function jt(t,n,e,r,i){const s=n.getQuaternion(St),o=(0,a.I0)(wt,s),c=n.getHalfSize(Ut);for(let t=0;t<8;++t){for(let n=0;n<3;++n)Ft[n]=c[n]*(t&1<<n?-1:1);for(let n=0;n<3;++n){let a=e[n];for(let t=0;t<3;++t)a+=Ft[t]*o[3*t+n];pt[3*t+n]=a}}(0,E.projectBuffer)(pt,t,0,pt,r,0,8),Rt(Dt,i)}const pt=new Array(24),Dt=new S.K(pt,3),Ft=(0,h.vt)(),zt=(0,h.vt)(),xt=(0,h.vt)(),Ut=(0,h.vt)(),wt=(0,r.vt)(),qt=(0,i.vt)(),yt=[[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0]],Vt=(0,h.vt)(),Gt=(0,h.vt)(),Xt=(0,h.vt)(),Bt=(0,h.CN)(-1,-1,-1)},67026:(t,n,e)=>{e.d(n,{A6:()=>E,Xd:()=>u,Xr:()=>d,hZ:()=>_,lw:()=>f,t2:()=>C,x8:()=>h});var a=e(29242),r=e(82534),i=e(51850),s=e(34304),o=e(38954),c=e(87317);function h(t,n,e){e*=.5;const a=Math.sin(e);return t[0]=a*n[0],t[1]=a*n[1],t[2]=a*n[2],t[3]=Math.cos(e),t}function u(t,n){const e=2*Math.acos(n[3]),a=Math.sin(e/2);return a>(0,s.FD)()?(t[0]=n[0]/a,t[1]=n[1]/a,t[2]=n[2]/a):(t[0]=1,t[1]=0,t[2]=0),e}function f(t,n,e){const a=n[0],r=n[1],i=n[2],s=n[3],o=e[0],c=e[1],h=e[2],u=e[3];return t[0]=a*u+s*o+r*h-i*c,t[1]=r*u+s*c+i*o-a*h,t[2]=i*u+s*h+a*c-r*o,t[3]=s*u-a*o-r*c-i*h,t}function l(t,n,e,a){const r=n[0],i=n[1],o=n[2],c=n[3];let h,u,f,l,d,I=e[0],E=e[1],M=e[2],_=e[3];return u=r*I+i*E+o*M+c*_,u<0&&(u=-u,I=-I,E=-E,M=-M,_=-_),1-u>(0,s.FD)()?(h=Math.acos(u),f=Math.sin(h),l=Math.sin((1-a)*h)/f,d=Math.sin(a*h)/f):(l=1-a,d=a),t[0]=l*r+d*I,t[1]=l*i+d*E,t[2]=l*o+d*M,t[3]=l*c+d*_,t}function d(t,n){return t[0]=-n[0],t[1]=-n[1],t[2]=-n[2],t[3]=n[3],t}function I(t,n){const e=n[0]+n[4]+n[8];let a;if(e>0)a=Math.sqrt(e+1),t[3]=.5*a,a=.5/a,t[0]=(n[5]-n[7])*a,t[1]=(n[6]-n[2])*a,t[2]=(n[1]-n[3])*a;else{let e=0;n[4]>n[0]&&(e=1),n[8]>n[3*e+e]&&(e=2);const r=(e+1)%3,i=(e+2)%3;a=Math.sqrt(n[3*e+e]-n[3*r+r]-n[3*i+i]+1),t[e]=.5*a,a=.5/a,t[3]=(n[3*r+i]-n[3*i+r])*a,t[r]=(n[3*r+e]+n[3*e+r])*a,t[i]=(n[3*i+e]+n[3*e+i])*a}return t}function E(t,n,e,a){const r=.5*Math.PI/180;n*=r,e*=r,a*=r;const i=Math.sin(n),s=Math.cos(n),o=Math.sin(e),c=Math.cos(e),h=Math.sin(a),u=Math.cos(a);return t[0]=i*c*u-s*o*h,t[1]=s*o*u+i*c*h,t[2]=s*c*h-i*o*u,t[3]=s*c*u+i*o*h,t}const M=c.c,_=c.s,N=c.g,T=f,v=c.d,A=c.h,S=c.l,m=c.j,O=m,g=c.b,P=g,R=c.n,C=c.a,b=c.e,L=(0,i.vt)(),j=(0,i.fA)(1,0,0),p=(0,i.fA)(0,1,0),D=(0,r.vt)(),F=(0,r.vt)(),z=(0,a.vt)();Object.freeze(Object.defineProperty({__proto__:null,add:N,calculateW:function(t,n){const e=n[0],a=n[1],r=n[2];return t[0]=e,t[1]=a,t[2]=r,t[3]=Math.sqrt(Math.abs(1-e*e-a*a-r*r)),t},conjugate:d,copy:M,dot:A,equals:b,exactEquals:C,fromEuler:E,fromMat3:I,getAxisAngle:u,identity:function(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t},invert:function(t,n){const e=n[0],a=n[1],r=n[2],i=n[3],s=e*e+a*a+r*r+i*i,o=s?1/s:0;return t[0]=-e*o,t[1]=-a*o,t[2]=-r*o,t[3]=i*o,t},len:O,length:m,lerp:S,mul:T,multiply:f,normalize:R,random:function(t){const n=s.Ov,e=n(),a=n(),r=n(),i=Math.sqrt(1-e),o=Math.sqrt(e);return t[0]=i*Math.sin(2*Math.PI*a),t[1]=i*Math.cos(2*Math.PI*a),t[2]=o*Math.sin(2*Math.PI*r),t[3]=o*Math.cos(2*Math.PI*r),t},rotateX:function(t,n,e){e*=.5;const a=n[0],r=n[1],i=n[2],s=n[3],o=Math.sin(e),c=Math.cos(e);return t[0]=a*c+s*o,t[1]=r*c+i*o,t[2]=i*c-r*o,t[3]=s*c-a*o,t},rotateY:function(t,n,e){e*=.5;const a=n[0],r=n[1],i=n[2],s=n[3],o=Math.sin(e),c=Math.cos(e);return t[0]=a*c-i*o,t[1]=r*c+s*o,t[2]=i*c+a*o,t[3]=s*c-r*o,t},rotateZ:function(t,n,e){e*=.5;const a=n[0],r=n[1],i=n[2],s=n[3],o=Math.sin(e),c=Math.cos(e);return t[0]=a*c+r*o,t[1]=r*c-a*o,t[2]=i*c+s*o,t[3]=s*c-i*o,t},rotationTo:function(t,n,e){const a=(0,o.e)(n,e);return a<-.999999?((0,o.h)(L,j,n),(0,o.H)(L)<1e-6&&(0,o.h)(L,p,n),(0,o.n)(L,L),h(t,L,Math.PI),t):a>.999999?(t[0]=0,t[1]=0,t[2]=0,t[3]=1,t):((0,o.h)(L,n,e),t[0]=L[0],t[1]=L[1],t[2]=L[2],t[3]=1+a,R(t,t))},scale:v,set:_,setAxes:function(t,n,e,a){const r=z;return r[0]=e[0],r[3]=e[1],r[6]=e[2],r[1]=a[0],r[4]=a[1],r[7]=a[2],r[2]=-n[0],r[5]=-n[1],r[8]=-n[2],R(t,I(t,r))},setAxisAngle:h,slerp:l,sqlerp:function(t,n,e,a,r,i){return l(D,n,r,i),l(F,e,a,i),l(t,D,F,2*i*(1-i)),t},sqrLen:P,squaredLength:g,str:function(t){return"quat("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"}},Symbol.toStringTag,{value:"Module"}))},98764:(t,n,e)=>{e.d(n,{Y0:()=>h,lO:()=>u});var a=e(73941),r=e(16930),i=e(21325);const s=new r.A(a.fv),o=new r.A(a.FY),c=new r.A(a.LJ),h=new r.A(a.Ro);function u(t){const n=f.get(t);if(n)return n;let e=s;if(t)if(t===o)e=o;else if(t===c)e=c;else{const n=t.wkid,a=t.latestWkid;if(null!=n||null!=a)(0,i.tl)(n)||(0,i.tl)(a)?e=o:((0,i.ZL)(n)||(0,i.ZL)(a))&&(e=c);else{const n=t.wkt2??t.wkt;if(n){const t=n.toUpperCase();t===l?e=o:t===d&&(e=c)}}}return f.set(t,e),e}const f=new Map,l=o.wkt.toUpperCase(),d=c.wkt.toUpperCase()}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5404],{95404:(e,r,t)=>{t.d(r,{computeObjectLayerResourceSize:()=>u}),t(78888);var i=t(49186),o=t(66344),n=t(51850),s=t(70328),l=t(8887);let c=new o.q(50);async function u(e,r=null){if(!e.isPrimitive){const r=e.resource?.href;if(!r)throw new i.A("symbol:invalid-resource","The symbol does not have a valid resource");const o=c.get(r);if(void 0!==o)return o;const{fetch:l}=await Promise.all([t.e(3030),t.e(7937),t.e(2944),t.e(9899),t.e(
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[5404],{95404:(e,r,t)=>{t.d(r,{computeObjectLayerResourceSize:()=>u}),t(78888);var i=t(49186),o=t(66344),n=t(51850),s=t(70328),l=t(8887);let c=new o.q(50);async function u(e,r=null){if(!e.isPrimitive){const r=e.resource?.href;if(!r)throw new i.A("symbol:invalid-resource","The symbol does not have a valid resource");const o=c.get(r);if(void 0!==o)return o;const{fetch:l}=await Promise.all([t.e(3030),t.e(7937),t.e(2944),t.e(9899),t.e(432),t.e(4304)]).then(t.bind(t,64304)),u=await l(r,{disableTextures:!0,spherical:!0}),a=(0,s.Ej)(u.referenceBoundingBox,(0,n.vt)());return c.put(r,a),a}if(!e.resource?.primitive)throw new i.A("symbol:invalid-resource","The symbol does not have a valid resource");const o=(0,s.vt)((0,l.Fq)(e.resource.primitive));if(null!=r)for(let e=0;e<o.length;e++)o[e]*=r;return(0,s.Ej)(o,(0,n.vt)())}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[4496],{1193:(t,n,e)=>{e.d(n,{H:()=>d});var r,o=e(90237),i=e(69540),a=e(25482),u=e(4718),l=e(53966),s=e(10107),c=e(79901),f=e(40608),p=e(31199);let d=r=class extends(i.A.ClonableMixin(a.A)){constructor(t){super(t),this.color=null,this.position=new Float64Array(0),this.uv=null,this.normal=null,this.tangent=null}castColor(t){return(0,p.b)(t,Uint8Array,[Uint8ClampedArray],{loggerTag:".color=",stride:4},l.A.getLogger(this))}castPosition(t){return t&&t instanceof Float32Array&&l.A.getLogger(this).warn(".position=","Setting position attribute from a Float32Array may cause precision problems. Consider storing data in a Float64Array or a regular number array"),(0,p.b)(t,Float64Array,[Float32Array],{loggerTag:".position=",stride:3},l.A.getLogger(this))}castUv(t){return(0,p.b)(t,Float32Array,[Float64Array],{loggerTag:".uv=",stride:2},l.A.getLogger(this))}castNormal(t){return(0,p.b)(t,Float32Array,[Float64Array],{loggerTag:".normal=",stride:3},l.A.getLogger(this))}castTangent(t){return(0,p.b)(t,Float32Array,[Float64Array],{loggerTag:".tangent=",stride:4},l.A.getLogger(this))}clonePositional(){const t={position:(0,u.o8)(this.position),normal:(0,u.o8)(this.normal),tangent:(0,u.o8)(this.tangent),uv:this.uv,color:this.color};return new r(t)}get usedMemory(){return this.position.byteLength+(this.uv?.byteLength??0)+(this.normal?.byteLength??0)+(this.tangent?.byteLength??0)+(this.color?.byteLength??0)}};(0,o._)([(0,s.MZ)({json:{write:p.B}})],d.prototype,"color",void 0),(0,o._)([(0,c.w)("color")],d.prototype,"castColor",null),(0,o._)([(0,s.MZ)({nonNullable:!0,json:{write:p.B}})],d.prototype,"position",void 0),(0,o._)([(0,c.w)("position")],d.prototype,"castPosition",null),(0,o._)([(0,s.MZ)({json:{write:p.B}})],d.prototype,"uv",void 0),(0,o._)([(0,c.w)("uv")],d.prototype,"castUv",null),(0,o._)([(0,s.MZ)({json:{write:p.B}})],d.prototype,"normal",void 0),(0,o._)([(0,c.w)("normal")],d.prototype,"castNormal",null),(0,o._)([(0,s.MZ)({json:{write:p.B}})],d.prototype,"tangent",void 0),(0,o._)([(0,c.w)("tangent")],d.prototype,"castTangent",null),d=r=(0,o._)([(0,f.$)("esri.geometry.support.MeshVertexAttributes")],d)},22141:(t,n,e)=>{e.d(n,{$5:()=>v,CN:()=>M,JP:()=>m,KM:()=>S,Mv:()=>_,X4:()=>A,gr:()=>T,qs:()=>w,si:()=>b,xA:()=>B});var r=e(34727),o=e(77690),i=e(29242),a=e(58083),u=e(9093),l=e(38954),s=e(51850),c=e(48353),f=e(9762),p=(e(79258),e(21325)),d=e(28735),g=e(13030),y=e(73354),h=e(65686);const m="Projection may be possible after calling projection.load().";function M(t,n,e,r){t.error(`Failed to project from (wkid:${n.wkid}) to (wkid:${e.wkid}).${r?" ":""}${r}`)}function A(t,n,e,r,o,i){return N(C.TO_PCPF,g.xs.fromTypedArray(t),R.NORMAL,g.Xm.fromTypedArray(n),e,g.Xm.fromTypedArray(r),o,g.xs.fromTypedArray(i))?i:null}function b(t,n,e,r,o,i){return N(C.FROM_PCPF,g.xs.fromTypedArray(t),R.NORMAL,g.Xm.fromTypedArray(n),e,g.Xm.fromTypedArray(r),o,g.xs.fromTypedArray(i))?i:null}function T(t,n,e,r){return(0,f.projectBuffer)(t,n,0,e,r,0)?e:null}function v(t,n,e,r){return(0,f.projectBuffer)(t,n,0,e,r,0)?e:null}function w(t,n,e){return(0,o.Ge)(L,e),(0,y.b)(n,t,L),(0,r.or)(L)&&(0,y.n)(n,n),n}function S(t,n,e){return(0,o.z0)(L,e),(0,h.t)(n,t,L),(0,r.or)(L)&&(0,y.n)(n,n,4),n}function B(t,n,e,r,o,i){if(!N(C.TO_PCPF,g.xs.fromTypedArray(t,4*Float32Array.BYTES_PER_ELEMENT),R.TANGENT,g.Xm.fromTypedArray(n),e,g.Xm.fromTypedArray(r),o,g.xs.fromTypedArray(i,4*Float32Array.BYTES_PER_ELEMENT)))return null;for(let n=3;n<t.length;n+=4)i[n]=t[n];return i}function _(t,n,e,r,o,i){if(!N(C.FROM_PCPF,g.xs.fromTypedArray(t,16),R.TANGENT,g.Xm.fromTypedArray(n),e,g.Xm.fromTypedArray(r),o,g.xs.fromTypedArray(i,16)))return null;for(let n=3;n<t.length;n+=4)i[n]=t[n];return i}var R,C,x;function E(t,n,e,r,i){switch((0,c.l)(r,e,P,r),t===C.FROM_PCPF&&(0,a.B8)(P,P),n){case R.NORMAL:return(0,o.Ge)(i,P);case R.TANGENT:return(0,o.z0)(i,P)}}function N(t,n,e,r,o,i,a,u){if(!n)return;const s=r.count;if(function(t){return t.isWGS84||(0,p.x1)(t)||(0,p.q8)(t)||(0,p.KQ)(t)}(o))for(let r=0;r<s;r++)i.getVec(r,F),n.getVec(r,O),(0,l.o)(O,O,E(t,e,F,a,L)),u.setVec(r,O);else for(let o=0;o<s;o++){i.getVec(o,F),n.getVec(o,O);const s=(0,d.jg)(r.get(o,1));let c=Math.cos(s);e===R.TANGENT!=(t===C.TO_PCPF)&&(c=1/c),E(t,e,F,a,L),t===C.TO_PCPF?(L[0]*=c,L[1]*=c,L[2]*=c,L[3]*=c,L[4]*=c,L[5]*=c):(L[0]*=c,L[3]*=c,L[6]*=c,L[1]*=c,L[4]*=c,L[7]*=c),(0,l.o)(O,O,L),(0,l.n)(O,O),u.setVec(o,O)}return u}(x=R||(R={}))[x.NORMAL=0]="NORMAL",x[x.TANGENT=1]="TANGENT",function(t){t[t.TO_PCPF=0]="TO_PCPF",t[t.FROM_PCPF=1]="FROM_PCPF"}(C||(C={}));const F=(0,s.vt)(),O=(0,s.vt)(),P=(0,u.vt)(),L=(0,i.vt)()},28846:(t,n,e)=>{e.d(n,{convertMeshVertexSpace:()=>s});var r=e(49186),o=e(4718),i=e(74887),a=e(1193),u=e(66895),l=e(72258);async function s(t,n,e){await Promise.resolve(),(0,i.Te)(e);const s=(0,l.UR)(t,n,{useEllipsoid:e?.useEllipsoid});if(!s)throw new r.A("meshUtils:convertVertexSpace()","Failed to convert to provided vertex space due to projection errors");return t.clone((0,u.Lz)(void 0,{vertexAttributes:new a.H({...s,uv:(0,o.o8)(t.vertexAttributes.uv),color:(0,o.o8)(t.vertexAttributes.color)}),vertexSpace:n,transform:null}))}},31199:(t,n,e)=>{function r(t,n,e,r){const{loggerTag:o,stride:i}=n;return t.length%i!==0?(r.error(o,`Invalid array length, expected a multiple of ${i}`),new e([])):t}function o(t,n,e,o,i){if(!t)return t;if(t instanceof n)return r(t,o,n,i);for(const a of e)if(t instanceof a)return r(new n(t),o,n,i);if(Array.isArray(t))return r(new n(t),o,n,i);{const r=e.map(t=>`'${t.name}'`);return i.error(`Failed to set property, expected one of ${r}, but got ${t.constructor.name}`),new n([])}}function i(t,n,e){n[e]=function(t){const n=new Array(t.length);for(let e=0;e<t.length;e++)n[e]=t[e];return n}(t)}e.d(n,{B:()=>i,b:()=>o})},48163:(t,n,e)=>{function r(){return[0,0]}function o(t){return[t[0],t[1]]}function i(t,n){return[t,n]}function a(){return i(1,1)}function u(){return i(1,0)}function l(){return i(0,1)}e.d(n,{Un:()=>s,fA:()=>i,o8:()=>o,vt:()=>r});const s=a(),c=u(),f=l();Object.freeze(Object.defineProperty({__proto__:null,ONES:s,UNIT_X:c,UNIT_Y:f,ZEROS:[0,0],clone:o,create:r,freeze:function(t,n){return[t,n]},fromArray:function(t,n=[0,0]){const e=Math.min(2,t.length);for(let r=0;r<e;++r)n[r]=t[r];return n},fromValues:i,ones:a,unitX:u,unitY:l,zeros:function(){return[0,0]}},Symbol.toStringTag,{value:"Module"}))},48353:(t,n,e)=>{e.d(n,{l:()=>s});var r=e(34727),o=e(58083),i=e(51850);function a(t,n,e){const r=Math.sin(t),o=Math.cos(t),i=Math.sin(n),a=Math.cos(n),u=e;return u[0]=-r,u[4]=-i*o,u[8]=a*o,u[12]=0,u[1]=o,u[5]=-i*r,u[9]=a*r,u[13]=0,u[2]=0,u[6]=a,u[10]=i,u[14]=0,u[3]=0,u[7]=0,u[11]=0,u[15]=1,u}var u=e(37539),l=e(21325);function s(t,n,e,r){const i=(0,u.Tp)(t,r);if(null==i)return!1;const s=i.source.spatialReferenceId,g=i.dest.spatialReferenceId;if(s===g&&!c(g)&&(s!==u.rz.UNKNOWN||(0,l.aI)(t,r)))return(0,o.kN)(e,n),!0;if(c(g)){const t=u.w5[s][u.rz.LON_LAT],r=u.w5[u.rz.LON_LAT][g];return null!=t&&null!=r&&(t(n,0,p,0),r(p,0,d,0),a(f*p[0],f*p[1],e),e[12]=d[0],e[13]=d[1],e[14]=d[2],!0)}const y=c(s);if((g===u.rz.WEB_MERCATOR||g===u.rz.PLATE_CARREE||g===u.rz.WGS84||g===u.rz.CGCS2000)&&(s===u.rz.WGS84||y||s===u.rz.WEB_MERCATOR||s===u.rz.CGCS2000)){const t=u.w5[s][u.rz.LON_LAT],r=u.w5[u.rz.LON_LAT][g];return null!=t&&null!=r&&(t(n,0,p,0),r(p,0,d,0),y?function(t,n,e){a(t,n,e),(0,o.mg)(e,e)}(f*p[0],f*p[1],e):(0,o.D_)(e),e[12]=d[0],e[13]=d[1],e[14]=d[2],!0)}return!1}function c(t){return t===u.rz.SPHERICAL_ECEF||t===u.rz.SPHERICAL_MARS_PCPF||t===u.rz.SPHERICAL_MOON_PCPF||t===u.rz.WGS84_ECEF}const f=(0,r.kU)(1),p=(0,i.vt)(),d=(0,i.vt)()},65686:(t,n,e)=>{e.d(n,{a:()=>i,b:()=>c,l:()=>s,n:()=>u,t:()=>a});var r=e(40876),o=(e(44208),e(53966));function i(t,n,e){a(t.typedBuffer,n.typedBuffer,e,t.typedBufferStride,n.typedBufferStride)}function a(t,n,e,r=4,o=r){if(t.length/r!==n.length/o)return;const i=t.length/r,a=e[0],u=e[1],l=e[2],s=e[3],c=e[4],f=e[5],p=e[6],d=e[7],g=e[8];let y=0,h=0;for(let e=0;e<i;e++){const e=n[y],i=n[y+1],m=n[y+2],M=n[y+3];t[h]=a*e+s*i+p*m,t[h+1]=u*e+c*i+d*m,t[h+2]=l*e+f*i+g*m,t[h+3]=M,y+=o,h+=r}}function u(t,n){const e=Math.min(t.count,n.count),r=t.typedBuffer,o=t.typedBufferStride,i=n.typedBuffer,a=n.typedBufferStride;for(let t=0;t<e;t++){const n=t*o,e=t*a,u=i[e],l=i[e+1],s=i[e+2],c=u*u+l*l+s*s;if(c>0){const t=1/Math.sqrt(c);r[n]=t*u,r[n+1]=t*l,r[n+2]=t*s}}}function l(t,n,e,r=4){const o=Math.min(t.length/r,n.count),i=n.typedBuffer,a=n.typedBufferStride;let u=0,l=0;for(let n=0;n<o;n++)t[l]=e*i[u],t[l+1]=e*i[u+1],t[l+2]=e*i[u+2],t[l+3]=e*i[u+3],u+=a,l+=r}function s(t,n,e,r){c(t.typedBuffer,n,e,r,t.typedBufferStride)}function c(t,n,e,o,i=4){const a=Math.min(t.length/i,n.count),u=n.typedBuffer,l=n.typedBufferStride;let s=0,c=0;const f=1/r.Tf;for(let n=0;n<a;n++)t[c]=o*(e*u[s])**f,t[c+1]=o*(e*u[s+1])**f,t[c+2]=o*(e*u[s+2])**f,t[c+3]=o*e*u[s+3],s+=l,c+=i}Object.freeze(Object.defineProperty({__proto__:null,linearToSRGB:c,linearToSRGBView:s,normalize:u,scale:l,scaleView:function(t,n,e){l(t.typedBuffer,n,e,t.typedBufferStride)},transformMat3:a,transformMat3View:i,transformMat4:function(t,n,e,r=4,i=r){if(t.length/r!==n.length/i)return void o.A.getLogger("esri.views.3d.support.buffer.math").error("source and destination buffers need to have the same number of elements");const a=t.length/r,u=e[0],l=e[1],s=e[2],c=e[3],f=e[4],p=e[5],d=e[6],g=e[7],y=e[8],h=e[9],m=e[10],M=e[11],A=e[12],b=e[13],T=e[14],v=e[15];let w=0,S=0;for(let e=0;e<a;e++){const e=n[w],o=n[w+1],a=n[w+2],B=n[w+3];t[S]=u*e+f*o+y*a+A*B,t[S+1]=l*e+p*o+h*a+b*B,t[S+2]=s*e+d*o+m*a+T*B,t[S+3]=c*e+g*o+M*a+v*B,w+=i,S+=r}},transformMat4View:function(t,n,e){if(t.count!==n.count)return;const r=t.count,o=e[0],i=e[1],a=e[2],u=e[3],l=e[4],s=e[5],c=e[6],f=e[7],p=e[8],d=e[9],g=e[10],y=e[11],h=e[12],m=e[13],M=e[14],A=e[15],b=t.typedBuffer,T=t.typedBufferStride,v=n.typedBuffer,w=n.typedBufferStride;for(let t=0;t<r;t++){const n=t*T,e=t*w,r=v[e],S=v[e+1],B=v[e+2],_=v[e+3];b[n]=o*r+l*S+p*B+h*_,b[n+1]=i*r+s*S+d*B+m*_,b[n+2]=a*r+c*S+g*B+M*_,b[n+3]=u*r+f*S+y*B+A*_}}},Symbol.toStringTag,{value:"Module"}))},65806:(t,n,e)=>{e.d(n,{g:()=>a});var r=e(51850),o=e(98988),i=e(9762);function a(t,n,e,r){if((0,o.canProjectWithoutEngine)(t.spatialReference,e)){u[0]=t.x,u[1]=t.y;const o=t.z;return u[2]=o??r??0,(0,i.projectBuffer)(u,t.spatialReference,0,n,e,0)}const a=(0,o.tryProjectWithZConversion)(t,e);return!!a&&(n[0]=a?.x,n[1]=a?.y,n[2]=a?.z??r??0,!0)}const u=(0,r.vt)()},66895:(t,n,e)=>{e.d(n,{$N:()=>c,Lz:()=>i,QN:()=>f,WO:()=>l,hz:()=>u,o2:()=>o});const r=Symbol("meshContext");function o(t){return t&&"object"==typeof t&&r in t?t[r]:void 0}function i(t,n){const e=o(t);return{...t,[r]:{...e,...n}}}const a=Symbol("meshMaterialContext");function u(t){return t&&"object"==typeof t&&a in t?t[a]:void 0}function l(t){const n=u(t);if(n?.materialMap)return t;const e={materialMap:new Map};return{...t,[a]:e}}const s=Symbol("meshTextureContext");function c(t){return t&&"object"==typeof t&&s in t?t[s]:void 0}function f(t){const n=c(t);if(n?.textureMap)return t;const e={textureMap:new Map};return{...t,[s]:e}}},72258:(t,n,e)=>{e.d(n,{UR:()=>T,p5:()=>b,xK:()=>R});var r=e(53966),o=e(34727),i=e(83047),a=e(77690),u=e(29242),l=e(58083),s=e(9093),c=e(38954),f=e(51850),p=e(98764),d=e(48353),g=e(65806),y=e(27615),h=e(21325),m=e(73354),M=e(22141);const A=()=>r.A.getLogger("esri.geometry.support.meshUtils.vertexSpaceConversion");function b(t,n,{vertexSpace:e,spatialReference:r}){if("georeferenced"===e.type){const o=t;if(!(0,g.g)(n,o,r))return!1;const{origin:i}=e;return(0,c.d)(t,o,i),!0}const o=(0,p.lO)(r),i=t;if(!(0,g.g)(n,i,o))return!1;const{origin:a}=e,u=F;if(!(0,d.l)(r,a,u,o))return!1;const s=(0,l.B8)(F,u);return null!=s&&((0,c.t)(t,i,s),!0)}function T(t,n,e){const{vertexSpace:r,transform:o,vertexAttributes:i}=t,u=(0,y.Hq)(r)?o:null,f=B(t.spatialReference,e,O.SOURCE_AND_TARGET);if((0,y.yJ)(r,n)&&(!u||(0,l.t2)(u.localMatrix,s.zK))&&_(f)){const{position:t,normal:n,tangent:r}=i,o=e?.allowBufferReuse;return{position:o?t:t.slice(),normal:o?n:n?.slice(),tangent:o?r:r?.slice()}}switch(t.vertexSpace.type){case"local":return"local"===n.type?function({vertexAttributes:t,spatialReference:n,transform:e},{origin:r},o,i){const a=v(n,i);if(!(0,d.l)(n,r,C,a))return(0,M.CN)(A(),n,a),null;if(e&&(0,l.lw)(C,C,e.localMatrix),!(0,d.l)(n,o,x,a))return(0,M.CN)(A(),a,n),null;(0,l.B8)(x,x);const u=(0,l.lw)(C,x,C);return S(u,n,i,O.SOURCE_AND_TARGET),w(t,u)}(t,t.vertexSpace,n.origin,e):function({spatialReference:t,vertexAttributes:n,transform:e},{origin:r},o,i){const a=v(t,i);if(!(0,d.l)(t,r,C,a))return(0,M.CN)(A(),t,a),null;e&&(0,l.lw)(C,C,e.localMatrix),S(C,t,i,O.SOURCE);const u=new Float64Array(n.position.length),s=function(t,n,e,r,o){(0,m.t)(r,t,n);const i=new Float64Array(t.length);return(0,M.$5)(r,o,i,e)?i:((0,M.CN)(A(),o,e),null)}(n.position,C,t,u,a);if(!s)return null;const f=function(t,n,e,r,o,i){if(null==o)return null;const a=new Float32Array(o.length);return(0,M.qs)(o,a,i),(0,M.si)(a,t,n,e,r,a)?a:((0,M.CN)(A(),r,n),null)}(s,t,u,a,n.normal,C);if(n.normal&&!f)return null;const p=function(t,n,e,r,o,i){if(null==o)return null;const a=new Float32Array(o.length);return(0,M.KM)(o,a,i),(0,M.Mv)(a,t,n,e,r,a)?a:((0,M.CN)(A(),r,n),null)}(s,t,u,a,n.tangent,C);if(n.tangent&&!p)return null;if(o){const t=(0,c.u)(N,o);(0,m.a)(s,s,t)}return{position:s,normal:f,tangent:p}}(t,t.vertexSpace,n.origin,e);case"georeferenced":return"local"===n.type?function({vertexAttributes:t,spatialReference:n,transform:e},{origin:r},o,i){const u=v(n,i);if(!(0,d.l)(n,o,C,u))return(0,M.CN)(A(),n,u),null;const s=1/B(n,i,O.TARGET);(0,l.hs)(C,C,[s,s,s]);const c=(0,l.B8)(x,C),{position:f,normal:p,tangent:g}=function(t,n,e){if(!n)return t;if(!e){const{position:e,normal:r,tangent:o}=t;return{position:(0,m.a)(new Float64Array(e.length),e,n),tangent:o,normal:r}}const r=w(t,e.localMatrix);return(0,m.a)(r.position,r.position,n),r}(t,r,e),y=new Float64Array(f.length),h=function(t,n,e,r,o){const i=(0,M.gr)(t,n,r,o);if(!i)return(0,M.CN)(A(),n,o),null;const a=new Float64Array(i.length);return(0,m.t)(a,i,e),a}(f,n,c,y,u);if(!h)return null;const b=(0,a.Ge)(E,c),T=function(t,n,e,r,o,i,a){if(null==t)return null;const u=a??new Float32Array(t.length);return(0,M.X4)(t,n,e,r,o,u)?((0,m.b)(u,u,i),u):((0,M.CN)(A(),e,o),null)}(p,f,n,y,u,b,p!==t.normal?p:void 0);if(!T&&p)return null;const S=function(t,n,e,r,o,i,a){if(null==t)return null;const u=a??new Float32Array(t.length);return(0,M.xA)(t,n,e,r,o,u)?((0,m.b)(u,u,i,4),u):((0,M.CN)(A(),e,o),null)}(g,f,n,y,u,b,g!==t.tangent?g:void 0);return!S&&g?null:{position:h,normal:T,tangent:S}}(t,t.vertexSpace,n.origin,e):function({vertexAttributes:t,transform:n,spatialReference:e},{origin:r},o,i){const a=B(e,i,O.SOURCE_AND_TARGET),u=r||!_(a)?(0,l.C)(C,n?.localMatrix??s.zK):null;u&&S(u,e,i,O.SOURCE_AND_TARGET);const{position:f,normal:p,tangent:d}=u?w(t,u):t,g=i?.allowBufferReuse,y=g?f:new Float64Array(f.length);let h=f;if(r&&(h=(0,m.a)(y,h,r)),o){const t=(0,c.u)(N,o);h=(0,m.a)(y,h,t)}return{position:h!==t.position||g?h:h.slice(),normal:p!==t.normal||g?p:p?.slice(),tangent:d!==t.tangent||g?d:d?.slice()}}(t,t.vertexSpace,n.origin,e)}}function v(t,n){return n?.useEllipsoid&&(0,h.B3)(t)?p.Y0:(0,p.lO)(t)}function w(t,n){const e=new Float64Array(t.position.length);(0,m.t)(e,t.position,n);const r=t.normal?new Float32Array(t.normal.length):null,o=t.tangent?new Float32Array(t.tangent.length):null;return r&&t.normal&&(0,M.qs)(t.normal,r,n),o&&t.tangent&&(0,M.KM)(t.tangent,o,n),{position:e,normal:r,tangent:o}}function S(t,n,e,r){const o=B(n,e,r);_(o)||(0,l.hs)(t,t,[o,o,o])}function B(t,n,e){const r=!!(e&O.SOURCE),o=!!(e&O.TARGET),i=n?.sourceUnit,a=n?.targetUnit;if(!i&&!a)return 1;let u=R(i,t);r||!i||_(u)||(A().warn("source unit conversion not supported"),u=1);let l=1/R(a,t);return o||!a||_(l)||(A().warn("target unit conversion not supported"),l=1),u*l}function _(t){return(0,o.Io)(t,1)}function R(t,n){if(null==t)return 1;const e=(0,i.KX)(n);return 1/(0,i.oU)(e,"meters",t)}const C=(0,s.vt)(),x=(0,s.vt)(),E=(0,u.vt)(),N=(0,f.vt)(),F=(0,s.vt)();var O,P;(P=O||(O={}))[P.NONE=0]="NONE",P[P.SOURCE=1]="SOURCE",P[P.TARGET=2]="TARGET",P[P.SOURCE_AND_TARGET=3]="SOURCE_AND_TARGET"},73354:(t,n,e)=>{e.d(n,{a:()=>f,b:()=>u,c:()=>a,d:()=>o,e:()=>p,f:()=>c,l:()=>s,n:()=>d,t:()=>i});var r=e(40876);function o(t,n,e){i(t.typedBuffer,n.typedBuffer,e,t.typedBufferStride,n.typedBufferStride)}function i(t,n,e,r=3,o=r){if(t.length/r!==Math.ceil(n.length/o))return t;const i=t.length/r,a=e[0],u=e[1],l=e[2],s=e[4],c=e[5],f=e[6],p=e[8],d=e[9],g=e[10],y=e[12],h=e[13],m=e[14];let M=0,A=0;for(let e=0;e<i;e++){const e=n[M],i=n[M+1],b=n[M+2];t[A]=a*e+s*i+p*b+y,t[A+1]=u*e+c*i+d*b+h,t[A+2]=l*e+f*i+g*b+m,M+=o,A+=r}return t}function a(t,n,e){u(t.typedBuffer,n.typedBuffer,e,t.typedBufferStride,n.typedBufferStride)}function u(t,n,e,r=3,o=r){if(t.length/r!==Math.ceil(n.length/o))return;const i=t.length/r,a=e[0],u=e[1],l=e[2],s=e[3],c=e[4],f=e[5],p=e[6],d=e[7],g=e[8];let y=0,h=0;for(let e=0;e<i;e++){const e=n[y],i=n[y+1],m=n[y+2];t[h]=a*e+s*i+p*m,t[h+1]=u*e+c*i+d*m,t[h+2]=l*e+f*i+g*m,y+=o,h+=r}}function l(t,n,e,r=3,o=r){const i=Math.min(t.length/r,n.length/o);let a=0,u=0;for(let l=0;l<i;l++)t[u]=e*n[a],t[u+1]=e*n[a+1],t[u+2]=e*n[a+2],a+=o,u+=r;return t}function s(t,n,e,r){c(t.typedBuffer,n.typedBuffer,e,r,t.typedBufferStride,n.typedBufferStride)}function c(t,n,e,o,i=3,a=i){const u=Math.min(t.length/i,n.length/a);let l=0,s=0;const c=1/r.Tf;for(let r=0;r<u;r++)t[s]=o*(e*n[l])**c,t[s+1]=o*(e*n[l+1])**c,t[s+2]=o*(e*n[l+2])**c,l+=a,s+=i}function f(t,n,e,r=3,o=r){const i=t.length/r;if(i!==Math.ceil(n.length/o))return t;let a=0,u=0;for(let l=0;l<i;l++)t[u]=n[a]+e[0],t[u+1]=n[a+1]+e[1],t[u+2]=n[a+2]+e[2],a+=o,u+=r;return t}function p(t,n){d(t.typedBuffer,n.typedBuffer,t.typedBufferStride,n.typedBufferStride)}function d(t,n,e=3,r=e){const o=Math.min(t.length/e,n.length/r);let i=0,a=0;for(let u=0;u<o;u++){const o=n[i],u=n[i+1],l=n[i+2],s=o*o+u*u+l*l;if(s>0){const n=1/Math.sqrt(s);t[a]=n*o,t[a+1]=n*u,t[a+2]=n*l}i+=r,a+=e}}e(44208),e(53966),Object.freeze(Object.defineProperty({__proto__:null,linearToSRGB:c,linearToSRGBView:s,normalize:d,normalizeView:p,scale:l,scaleView:function(t,n,e){l(t.typedBuffer,n.typedBuffer,e,t.typedBufferStride,n.typedBufferStride)},shiftRight:function(t,n,e){const r=Math.min(t.count,n.count),o=t.typedBuffer,i=t.typedBufferStride,a=n.typedBuffer,u=n.typedBufferStride;let l=0,s=0;for(let t=0;t<r;t++)o[s]=a[l]>>e,o[s+1]=a[l+1]>>e,o[s+2]=a[l+2]>>e,l+=u,s+=i},transformMat3:u,transformMat3View:a,transformMat4:i,transformMat4View:o,translate:f},Symbol.toStringTag,{value:"Module"}))},77690:(t,n,e)=>{e.d(n,{B8:()=>u,Ge:()=>p,I0:()=>f,KC:()=>l,hZ:()=>i,hs:()=>c,lw:()=>s,mg:()=>a,z0:()=>o});var r=e(34304);function o(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[4],t[4]=n[5],t[5]=n[6],t[6]=n[8],t[7]=n[9],t[8]=n[10],t}function i(t,n,e,r,o,i,a,u,l,s){return t[0]=n,t[1]=e,t[2]=r,t[3]=o,t[4]=i,t[5]=a,t[6]=u,t[7]=l,t[8]=s,t}function a(t,n){if(t===n){const e=n[1],r=n[2],o=n[5];t[1]=n[3],t[2]=n[6],t[3]=e,t[5]=n[7],t[6]=r,t[7]=o}else t[0]=n[0],t[1]=n[3],t[2]=n[6],t[3]=n[1],t[4]=n[4],t[5]=n[7],t[6]=n[2],t[7]=n[5],t[8]=n[8];return t}function u(t,n){const e=n[0],r=n[1],o=n[2],i=n[3],a=n[4],u=n[5],l=n[6],s=n[7],c=n[8],f=c*a-u*s,p=-c*i+u*l,d=s*i-a*l;let g=e*f+r*p+o*d;return g?(g=1/g,t[0]=f*g,t[1]=(-c*r+o*s)*g,t[2]=(u*r-o*a)*g,t[3]=p*g,t[4]=(c*e-o*l)*g,t[5]=(-u*e+o*i)*g,t[6]=d*g,t[7]=(-s*e+r*l)*g,t[8]=(a*e-r*i)*g,t):null}function l(t,n){const e=n[0],r=n[1],o=n[2],i=n[3],a=n[4],u=n[5],l=n[6],s=n[7],c=n[8];return t[0]=a*c-u*s,t[1]=o*s-r*c,t[2]=r*u-o*a,t[3]=u*l-i*c,t[4]=e*c-o*l,t[5]=o*i-e*u,t[6]=i*s-a*l,t[7]=r*l-e*s,t[8]=e*a-r*i,t}function s(t,n,e){const r=n[0],o=n[1],i=n[2],a=n[3],u=n[4],l=n[5],s=n[6],c=n[7],f=n[8],p=e[0],d=e[1],g=e[2],y=e[3],h=e[4],m=e[5],M=e[6],A=e[7],b=e[8];return t[0]=p*r+d*a+g*s,t[1]=p*o+d*u+g*c,t[2]=p*i+d*l+g*f,t[3]=y*r+h*a+m*s,t[4]=y*o+h*u+m*c,t[5]=y*i+h*l+m*f,t[6]=M*r+A*a+b*s,t[7]=M*o+A*u+b*c,t[8]=M*i+A*l+b*f,t}function c(t,n,e){const r=e[0],o=e[1],i=e[2];return t[0]=r*n[0],t[1]=r*n[1],t[2]=r*n[2],t[3]=o*n[3],t[4]=o*n[4],t[5]=o*n[5],t[6]=i*n[6],t[7]=i*n[7],t[8]=i*n[8],t}function f(t,n){const e=n[0],r=n[1],o=n[2],i=n[3],a=e+e,u=r+r,l=o+o,s=e*a,c=r*a,f=r*u,p=o*a,d=o*u,g=o*l,y=i*a,h=i*u,m=i*l;return t[0]=1-f-g,t[3]=c-m,t[6]=p+h,t[1]=c+m,t[4]=1-s-g,t[7]=d-y,t[2]=p-h,t[5]=d+y,t[8]=1-s-f,t}function p(t,n){const e=n[0],r=n[1],o=n[2],i=n[3],a=n[4],u=n[5],l=n[6],s=n[7],c=n[8],f=n[9],p=n[10],d=n[11],g=n[12],y=n[13],h=n[14],m=n[15],M=e*u-r*a,A=e*l-o*a,b=e*s-i*a,T=r*l-o*u,v=r*s-i*u,w=o*s-i*l,S=c*y-f*g,B=c*h-p*g,_=c*m-d*g,R=f*h-p*y,C=f*m-d*y,x=p*m-d*h;let E=M*x-A*C+b*R+T*_-v*B+w*S;return E?(E=1/E,t[0]=(u*x-l*C+s*R)*E,t[1]=(l*_-a*x-s*B)*E,t[2]=(a*C-u*_+s*S)*E,t[3]=(o*C-r*x-i*R)*E,t[4]=(e*x-o*_+i*B)*E,t[5]=(r*_-e*C-i*S)*E,t[6]=(y*w-h*v+m*T)*E,t[7]=(h*b-g*w-m*A)*E,t[8]=(g*v-y*b+m*M)*E,t):null}function d(t,n,e){return t[0]=n[0]-e[0],t[1]=n[1]-e[1],t[2]=n[2]-e[2],t[3]=n[3]-e[3],t[4]=n[4]-e[4],t[5]=n[5]-e[5],t[6]=n[6]-e[6],t[7]=n[7]-e[7],t[8]=n[8]-e[8],t}const g=s,y=d;Object.freeze(Object.defineProperty({__proto__:null,add:function(t,n,e){return t[0]=n[0]+e[0],t[1]=n[1]+e[1],t[2]=n[2]+e[2],t[3]=n[3]+e[3],t[4]=n[4]+e[4],t[5]=n[5]+e[5],t[6]=n[6]+e[6],t[7]=n[7]+e[7],t[8]=n[8]+e[8],t},adjoint:l,copy:function(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t},determinant:function(t){const n=t[0],e=t[1],r=t[2],o=t[3],i=t[4],a=t[5],u=t[6],l=t[7],s=t[8];return n*(s*i-a*l)+e*(-s*o+a*u)+r*(l*o-i*u)},equals:function(t,n){const e=t[0],o=t[1],i=t[2],a=t[3],u=t[4],l=t[5],s=t[6],c=t[7],f=t[8],p=n[0],d=n[1],g=n[2],y=n[3],h=n[4],m=n[5],M=n[6],A=n[7],b=n[8],T=(0,r.FD)();return Math.abs(e-p)<=T*Math.max(1,Math.abs(e),Math.abs(p))&&Math.abs(o-d)<=T*Math.max(1,Math.abs(o),Math.abs(d))&&Math.abs(i-g)<=T*Math.max(1,Math.abs(i),Math.abs(g))&&Math.abs(a-y)<=T*Math.max(1,Math.abs(a),Math.abs(y))&&Math.abs(u-h)<=T*Math.max(1,Math.abs(u),Math.abs(h))&&Math.abs(l-m)<=T*Math.max(1,Math.abs(l),Math.abs(m))&&Math.abs(s-M)<=T*Math.max(1,Math.abs(s),Math.abs(M))&&Math.abs(c-A)<=T*Math.max(1,Math.abs(c),Math.abs(A))&&Math.abs(f-b)<=T*Math.max(1,Math.abs(f),Math.abs(b))},exactEquals:function(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]&&t[6]===n[6]&&t[7]===n[7]&&t[8]===n[8]},frob:function(t){return Math.sqrt(t[0]**2+t[1]**2+t[2]**2+t[3]**2+t[4]**2+t[5]**2+t[6]**2+t[7]**2+t[8]**2)},fromMat2d:function(t,n){return t[0]=n[0],t[1]=n[1],t[2]=0,t[3]=n[2],t[4]=n[3],t[5]=0,t[6]=n[4],t[7]=n[5],t[8]=1,t},fromMat4:o,fromQuat:f,fromRotation:function(t,n){const e=Math.sin(n),r=Math.cos(n);return t[0]=r,t[1]=e,t[2]=0,t[3]=-e,t[4]=r,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},fromScaling:function(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=0,t[4]=n[1],t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},fromTranslation:function(t,n){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=n[0],t[7]=n[1],t[8]=1,t},identity:function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},invert:u,isOrthoNormal:function(t){const n=(0,r.FD)(),e=t[0],o=t[1],i=t[2],a=t[3],u=t[4],l=t[5],s=t[6],c=t[7],f=t[8];return Math.abs(1-(e*e+a*a+s*s))<=n&&Math.abs(1-(o*o+u*u+c*c))<=n&&Math.abs(1-(i*i+l*l+f*f))<=n},mul:g,multiply:s,multiplyScalar:function(t,n,e){return t[0]=n[0]*e,t[1]=n[1]*e,t[2]=n[2]*e,t[3]=n[3]*e,t[4]=n[4]*e,t[5]=n[5]*e,t[6]=n[6]*e,t[7]=n[7]*e,t[8]=n[8]*e,t},multiplyScalarAndAdd:function(t,n,e,r){return t[0]=n[0]+e[0]*r,t[1]=n[1]+e[1]*r,t[2]=n[2]+e[2]*r,t[3]=n[3]+e[3]*r,t[4]=n[4]+e[4]*r,t[5]=n[5]+e[5]*r,t[6]=n[6]+e[6]*r,t[7]=n[7]+e[7]*r,t[8]=n[8]+e[8]*r,t},normalFromMat4:p,normalFromMat4Legacy:function(t,n){const e=n[0],r=n[1],o=n[2],i=n[4],a=n[5],u=n[6],l=n[8],s=n[9],c=n[10],f=c*a-u*s,p=-c*i+u*l,d=s*i-a*l,g=e*f+r*p+o*d;if(!g)return null;const y=1/g;return t[0]=f*y,t[1]=(-c*r+o*s)*y,t[2]=(u*r-o*a)*y,t[3]=p*y,t[4]=(c*e-o*l)*y,t[5]=(-u*e+o*i)*y,t[6]=d*y,t[7]=(-s*e+r*l)*y,t[8]=(a*e-r*i)*y,t},projection:function(t,n,e){return t[0]=2/n,t[1]=0,t[2]=0,t[3]=0,t[4]=-2/e,t[5]=0,t[6]=-1,t[7]=1,t[8]=1,t},rotate:function(t,n,e){const r=n[0],o=n[1],i=n[2],a=n[3],u=n[4],l=n[5],s=n[6],c=n[7],f=n[8],p=Math.sin(e),d=Math.cos(e);return t[0]=d*r+p*a,t[1]=d*o+p*u,t[2]=d*i+p*l,t[3]=d*a-p*r,t[4]=d*u-p*o,t[5]=d*l-p*i,t[6]=s,t[7]=c,t[8]=f,t},scale:c,scaleByVec2:function(t,n,e){const r=e[0],o=e[1];return t[0]=r*n[0],t[1]=r*n[1],t[2]=r*n[2],t[3]=o*n[3],t[4]=o*n[4],t[5]=o*n[5],t},set:i,str:function(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"},sub:y,subtract:d,translate:function(t,n,e){const r=n[0],o=n[1],i=n[2],a=n[3],u=n[4],l=n[5],s=n[6],c=n[7],f=n[8],p=e[0],d=e[1];return t[0]=r,t[1]=o,t[2]=i,t[3]=a,t[4]=u,t[5]=l,t[6]=p*r+d*a+s,t[7]=p*o+d*u+c,t[8]=p*i+d*l+f,t},transpose:a},Symbol.toStringTag,{value:"Module"}))},98764:(t,n,e)=>{e.d(n,{Y0:()=>s,lO:()=>c});var r=e(73941),o=e(16930),i=e(21325);const a=new o.A(r.fv),u=new o.A(r.FY),l=new o.A(r.LJ),s=new o.A(r.Ro);function c(t){const n=f.get(t);if(n)return n;let e=a;if(t)if(t===u)e=u;else if(t===l)e=l;else{const n=t.wkid,r=t.latestWkid;if(null!=n||null!=r)(0,i.tl)(n)||(0,i.tl)(r)?e=u:((0,i.ZL)(n)||(0,i.ZL)(r))&&(e=l);else{const n=t.wkt2??t.wkt;if(n){const t=n.toUpperCase();t===p?e=u:t===d&&(e=l)}}}return f.set(t,e),e}const f=new Map,p=u.wkt.toUpperCase(),d=l.wkt.toUpperCase()}}]);
|